1
0
mirror of https://github.com/mrclay/minify.git synced 2025-09-09 05:30:41 +02:00

min/index.php : Allow far-off expires on f= URIs

min/README.txt : + docs for far-off expires
This commit is contained in:
Steve Clay
2008-10-28 00:25:40 +00:00
parent 717399a062
commit 6ccdc5f253
2 changed files with 32 additions and 21 deletions

View File

@@ -29,15 +29,14 @@ if (0 === stripos(PHP_OS, 'win')) {
if ($min_allowDebugFlag && isset($_GET['debug'])) {
$min_serveOptions['debug'] = true;
}
// check for URI versioning
if (preg_match('/&\\d/', $_SERVER['QUERY_STRING'])) {
$min_serveOptions['maxAge'] = 31536000;
}
if (isset($_GET['g'])) {
// well need groups config
$min_serveOptions['minApp']['groups'] = (require MINIFY_MIN_DIR . '/groupsConfig.php');
// check for URI versioning
if (preg_match('/&\\d/', $_SERVER['QUERY_STRING'])) {
$min_serveOptions['maxAge'] = 31536000;
}
}
if (isset($_GET['f']) || isset($_GET['g'])) {
// serve!
Minify::serve('MinApp', $min_serveOptions);