php获取设备型号-成都快上网建站

php获取设备型号

/*
 获取设备型号
 */
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://kswjz.com/article/giopgj.html
扫二维码与项目经理沟通

我们在微信上24小时期待你的声音

解答本文疑问/技术咨询/运营咨询/技术建议/互联网交流