开发者

JqueryMobile Splash page for non-mobile

I´m using jquerymobile to build a simple mobile app and would like to know, whats the best way one should use to make a index page for non-mobile browsers when visiting the mobile app adress ?

I use开发者_如何学Go index.html for now, and i can access it with any desktop browser, but i would want to restrict it to mobile only, and show a different page for desktop browsers.

Which approuch would be better?

Thank you!


In your index.html page you can include some detection script that detects the type of browser (it may be easier to use a whitelist of mobile devices rather then a blacklist of desktop browsers) and then redirects desktop browsers to something like index_desktop.html.

Sorry if the answer isn't as exact as you would have liked but I generally allow desktop browsers the ability to view my mobile pages (I just make sure there is a "View Desktop Version" link somewhere on the page.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜