function mobile_tools_footer in Mobile Tools 6.3
Implementation of hook_footer()
- inserting some javascript to hide navigation bar
File
- ./
mobile_tools.module, line 704 - Mobile Tools provides a range of functionality assisting in creating a mobile Drupal site . this functionality contains:
Code
function mobile_tools_footer() {
$output = '';
$site = mobile_tools_site_type();
if (variable_get('mobile_tools_hide_address_bar', 1) && $site == 'mobile') {
$output .= '<script type="text/javascript" charset="utf-8">';
$output .= <<<EOF
addEventListener('load', function() {
\tsetTimeout(hideAddressBar, 0);
}, false);
function hideAddressBar() {
\twindow.scrollTo(0, 1);
}
EOF;
$output .= '</script>';
}
return $output;
}