livechat.install in LiveChat 7
Same filename and directory in other branches
Installation file for the LiveChat module.
File
livechat.installView source
<?php
/**
* @file
* Installation file for the LiveChat module.
*/
/**
* Implements hook_requirements().
*/
function livechat_requirements($phase) {
$requirements = array();
$t = get_t();
if ($phase == 'runtime') {
// Raise warning if a LiveChat license has not been installed yet.
if (!livechat_is_installed()) {
$requirements['livechat'] = array(
'title' => $t('LiveChat'),
'description' => $t('A LiveChat license has not been installed. Please go to <a href="@url">LiveChat settings</a>.', array(
'@url' => url('admin/config/services/livechat/install'),
)),
'severity' => REQUIREMENT_ERROR,
'value' => $t('Not configured'),
);
}
}
return $requirements;
}
/**
* Implements hook_uninstall().
*/
function livechat_uninstall() {
variable_del('livechat_license');
variable_del('livechat_visibility');
variable_del('livechat_pages');
variable_del('livechat_exclude_system_paths');
}
Functions
Name | Description |
---|---|
livechat_requirements | Implements hook_requirements(). |
livechat_uninstall | Implements hook_uninstall(). |