function advagg_enable in Advanced CSS/JS Aggregation 7
Same name and namespace in other branches
- 6 advagg.install \advagg_enable()
- 7.2 advagg.install \advagg_enable()
Implements hook_enable().
File
- ./
advagg.install, line 11 - Handles Advanced Aggregation installation and upgrade tasks.
Code
function advagg_enable() {
// Create the advagg_css/ path within the files folder.
$css_path = 'public://advagg_css';
file_prepare_directory($css_path, FILE_CREATE_DIRECTORY);
$js_path = 'public://advagg_js';
// Create the advagg_js/ path within the files folder.
file_prepare_directory($js_path, FILE_CREATE_DIRECTORY);
// Include the module file.
register_shutdown_function('drupal_load', 'module', 'advagg');
// Rescan files.
register_shutdown_function('advagg_flush_caches');
// Check for fast404.
register_shutdown_function('advagg_check_missing_handler');
if (module_exists('javascript_aggregator')) {
variable_set('advagg_closure', FALSE);
}
}