block_refresh.install in Block Refresh 6
Same filename and directory in other branches
Install, update and uninstall functions for the block_refresh module.
File
block_refresh.installView source
<?php
/**
* @file
* Install, update and uninstall functions for the block_refresh module.
*/
function block_refresh_install() {
block_refresh_reset_jq();
drupal_set_message('Be sure to set appropriate permissions for Block Refresh to function properly!', 'warning');
}
// Support for block_refresh plugin
function block_refresh_update_1() {
block_refresh_reset_jq();
}
// Add settings menu item, and change access to /block_refresh
function block_refresh_update_2() {
menu_rebuild();
}
/**
* Register new plugin with jQ
*/
function block_refresh_reset_jq() {
cache_clear_all('jq_plugins', 'cache');
}
/**
* Implementation of hook_uninstall().
*/
function block_refresh_uninstall() {
db_query("DELETE FROM {variable} WHERE name LIKE 'block_refresh_%'");
}
Functions
Name | Description |
---|---|
block_refresh_install | @file Install, update and uninstall functions for the block_refresh module. |
block_refresh_reset_jq | Register new plugin with jQ |
block_refresh_uninstall | Implementation of hook_uninstall(). |
block_refresh_update_1 | |
block_refresh_update_2 |