例如,
<div style='display:none;'>
<!-- JavaScript scripts and php function that otherwise would run automatically -->
</div>
。比方说,我喜欢在移动设备上运行时不能运行的脚本。这有可能用CSS吗?
答案 0 :(得分:0)
如果您想要一个不适合移动用户的JS代码,您可以这样做
if (!(typeof window.orientation !== 'undefined')) {
//Code that is not available for mobile users
}