function mobile_theme_detect_subdomain in Mobile Theme 6
Same name and namespace in other branches
- 7 mobile_theme.module \mobile_theme_detect_subdomain()
Detect whether the user is on a mobile device by checking the subdomain.
File
- ./
mobile_theme.module, line 108
Code
function mobile_theme_detect_subdomain() {
$m = variable_get('mobile_theme_subdomain', 'm.');
return substr($_SERVER['HTTP_HOST'], 0, strlen($m)) === $m;
}