/* 获取设备型号 */function get_device_type(){ ???$agent = strtolower($_SERVER[‘HTTP_USER_AGENT‘]); ???$type = ‘other‘; ???if(strpos($agent, ‘iphone‘) || strpos($agent, ‘ipad‘) ){ ???????$type = ‘ios‘; ???} ???if(strpos($agent, ‘android‘)){ ???????$type = ‘android‘; ???} ???return $type;}
php获取设备型号
原文地址:http://blog.51cto.com/12173069/2173191