开发者

can browsers select scripts based on user's viewing resolution?

I want to implement a JQuery script that requires the browser's width at 100% which depends solely on the user's viewing resolution. Can i prepare multiple scripts for the different resolutions for the browser to automatically detect and choose or does there need to be a single script with if/then clause开发者_StackOverflows?


Apparently the can via Javascript using screen.width and screen.height.


While I don't know what exactly you are trying to implement, you might want to look into CSS media queries as an interesting approach to adaptive Layouts.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜