blogbysid.wordpress.com
Detecting Device Type in a web application: Mobile, Tablet or Desktop
To check whether the request is coming from mobile, tablet or desktop. function detectDevice() { $tablet_browser = 0; $mobile_browser = 0; if (preg_match(‘/(tablet|ipad|playbook)|(android(?!.…