English 中文(简体)
用户Agent.match - 具体手提识别
原标题:Navigator.userAgent.match - specific handset identification

当用户使用某些电话时,使用电动器、用户Agent.match,但与安乐团一起使用时,I m recognising是许多片面/电话/打头箱。 So I ve got

if(navigator.userAgent.match(/android/i)){

但是,我如何从安乐斯名单上挑选一个HTC One S? 用户代理人是:

user-agent: Mozilla/5.0 (Linux; U; Android 4.0.3; en-gb; HTC_One_S Build/IML74K) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30

我可以说是安的4.0,但当时有许多产品是安的4.0。 下一步是检查我可以做的屏幕大小,但是,如果航行者是用户,就能够具体检查。 AgentcompACTLY a HTC One S?

最佳回答

Maybe if(navigator.userAgent.match(/HTC_One_S/i){?

问题回答

暂无回答




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签