extlink_extra.install in External Links Extra 7
Installation file for extlink_extra
File
extlink_extra.installView source
<?php
/**
* @file
* Installation file for extlink_extra
*/
function extlink_extra_enable() {
/* Turn on the colorbox module's "Enable Colorbox inline" setting
This enables custom links that can open inline content in a Colorbox. Add the class "colorbox-inline" to the link
and build the url like this "?width=500&height=500&inline=true#id-of-content".
Other modules may activate this for easy Colorbox integration. */
variable_set('colorbox_inline', 1);
drupal_set_message(t('Activated the "Enable Colorbox inline" setting.'));
// Figure out what extlink.module's system weight is and add 1 to it so that
// our scripts and such will be executed afterwards.
$extlink_weight = db_query("SELECT weight FROM {system} WHERE type = 'module' AND name = 'extlink'")
->fetchField(0);
db_query("UPDATE {system} SET weight = :weight WHERE type = 'module' AND name = 'extlink_extra'", array(
':weight' => ++$extlink_weight,
));
}
/**
* Implementation of hook_uninstall().
*/
function extlink_extra_uninstall() {
variable_del('extlink_page_title');
variable_del('extlink_alert_text');
variable_del('extlink_alert_type');
variable_del('extlink_alert_timer');
}
Functions
Name | Description |
---|---|
extlink_extra_enable | @file Installation file for extlink_extra |
extlink_extra_uninstall | Implementation of hook_uninstall(). |