function agrcache_menu in Aggregate cache 7
Implements hook_menu().
File
- ./
agrcache.module, line 11 - Provides imagecache style generation of css/js aggregates.
Code
function agrcache_menu() {
$directory_path = variable_get('file_public_path', conf_path() . '/files');
foreach (array(
'css',
'js',
) as $type) {
$items[$directory_path . "/{$type}/%"] = array(
'title' => "Generate {$type} aggregate",
'page callback' => 'agrcache_generate_aggregate',
'page arguments' => array(
count(explode('/', $directory_path)) + 1,
$type,
),
'access callback' => TRUE,
'type' => MENU_CALLBACK,
);
}
return $items;
}