-
Notifications
You must be signed in to change notification settings - Fork 0
/
allegro.install
38 lines (33 loc) · 887 Bytes
/
allegro.install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
/**
* @file
* Install hooks for the Allegro API module.
*/
/**
* Implements hook_requirements().
*/
function allegro_requirements($phase) {
// Ensure translations don't break at install time.
$t = get_t();
$requirements = array();
if (!class_exists('SoapClient')) {
$requirements['allegro_soap'] += array(
'title' => $t('PHP SoapClient class'),
'severity' => REQUIREMENT_ERROR,
'description' => $t(
'Allegro requires the PHP <a href="@soap-url">SOAP extension</a>.',
array('@soap-url' => 'http://php.net/manual/en/book.soap.php')),
);
}
return $requirements;
}
/**
* Implements hook_uninstall().
*/
function allegro_uninstall() {
variable_del('allegro_login');
variable_del('allegro_password');
variable_del('allegro_webapikey');
variable_del('allegro_country_code');
variable_del('allegro_test_mode');
}