clientside_validation.install in Clientside Validation 6
Same filename and directory in other branches
File
clientside_validation.installView source
<?php
/*
* @file
* Clientside validation install file
*/
/**
* Implements hook_install
*/
function clientside_validation_enable() {
//support for module like e.g. select_or_other
db_query("UPDATE {system} SET weight = 5 WHERE name = '%s'", "clientside_validation");
}
/**
* Clientside validation was split up into form validation, webform validation and fapi validation.
* This update enables the form and webform clientside validation module. It does not enable the
* fapi clientside validation module, because it's a new feature since this release.
*/
function clientside_validation_update_6100() {
module_enable(array(
'clientside_validation_form',
'clientside_validation_webform',
));
return array(
array(
'success' => TRUE,
),
);
}
/**
* Dependencies changed, enable the right modules.
*/
function clientside_validation_update_6101() {
$dependants = array(
'clientside_validation_fapi',
'clientside_validation_webform',
);
foreach ($dependants as $dependant) {
if (module_exists($dependant) && !module_exists('clientside_validation_form')) {
module_enable(array(
'clientside_validation_form',
));
break;
}
}
return array(
array(
'success' => TRUE,
),
);
}
Functions
Name | Description |
---|---|
clientside_validation_enable | Implements hook_install |
clientside_validation_update_6100 | Clientside validation was split up into form validation, webform validation and fapi validation. This update enables the form and webform clientside validation module. It does not enable the fapi clientside validation module, because it's a new… |
clientside_validation_update_6101 | Dependencies changed, enable the right modules. |