PHP获取客户端设备的类型
function get_device_type(){
	$agent = strtolower($_SERVER['HTTP_USER_AGENT']);
	if(strpos($agent, 'iphone') || strpos($agent, 'ipad') || strpos($agent, 'android')){
		$type = 'mobile';
	}else{
		$type = 'computer';
	}
	return $type;
}


鄂ICP备19018033号-1
0.087841s