function lazy_install in Lazy-load 7
Same name and namespace in other branches
- 8.3 lazy.install \lazy_install()
Implements hook_install().
File
- ./
lazy.install, line 11 - Install, update, and uninstall functions for the Lazy-load module.
Code
function lazy_install() {
$defaults = array(
'lazy_filter_errorClass' => 'b-error',
'lazy_filter_loadInvisible' => FALSE,
'lazy_filter_offset' => 100,
'lazy_filter_saveViewportOffsetDelay' => 50,
'lazy_filter_selector' => 'b-lazy',
'lazy_filter_alter_tag' => array(
'img' => 'img',
'iframe' => 'iframe',
),
'lazy_filter_skipClass' => 'no-b-lazy',
'lazy_filter_src' => 'data-src',
'lazy_filter_successClass' => 'b-loaded',
'lazy_filter_validateDelay' => 25,
'lazy_filter_placeholderSrc' => 'data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==',
'lazy_disabled_paths' => 'rss.xml',
'lazy_prefer_native' => FALSE,
);
variable_set('lazy_filter_defaults', $defaults);
foreach ($defaults as $key => $value) {
variable_set($key, $value);
}
}