? my $ctx = $main::context; ? $_mt->wrapper_file("wrapper.mt", "Configure", "Expires Directives")->(sub {
This document describes the configuration directives of the expires handler.
$ctx->{directive}->( name => "expires", levels => [ qw(global host path extension) ], desc => <<'EOT', An optional directive for setting theCache-Control: max-age=
header.
EOT
)->(sub {
?>
OFF
the feature is not used
NUMBER UNIT
then the header is set
second
, minute
, hour
, day
, month
, year
Cache-Control: max-age=86400
', <<'EOT')
expires: 1 day
EOT
?>
You can also find an example that conditionally sets the header depending on the aspects of a request in Modifying the Response section of the Mruby directives documentation.
? }) ? })