function calendar_enable in Calendar 5.2
Same name and namespace in other branches
- 5 calendar.install \calendar_enable()
- 6.2 calendar.install \calendar_enable()
- 7 calendar.install \calendar_enable()
- 7.2 calendar.install \calendar_enable()
Implementation of hook_enable(). Reset the calendar caches.
File
- ./
calendar.install, line 61 - Install File
Code
function calendar_enable() {
module_enable(array(
'date_api',
));
if (version_compare(PHP_VERSION, '5.2', '<')) {
module_enable(array(
'date_php4',
));
}
module_enable(array(
'date_timezone',
));
cache_clear_all('calendar_views', 'cache_views');
cache_clear_all('calendar_fields', 'cache_views');
}