html5禁止横屏的方法:首先打开相应的HTML5代码文件;然后在head区域中添加“<meta name=”screen-orientation” content=”portrait”>”即可禁止html5页面横屏。
本文操作环境:windows7系统、HTML5&&CSS3版、Dell G3电脑。
禁止手机端html5页面横屏
禁止手机端html5页面横屏,uc浏览器和qq浏览器禁止横屏代码如下,meta标签添加到head区域<meta name="screen-orientation" content="portrait">
uc浏览器强制竖屏
<meta name="screen-orientation" content="portrait">
QQ浏览器强制竖屏
<meta name="x5-orientation" content="portrait">
UC浏览器强制全屏
<meta name="full-screen" content="yes">
QQ浏览器强制全屏
<meta name="x5-fullscreen" content="true">
UC浏览器应用模式
<meta name="browsermode" content="application">
QQ浏览器应用模式
<meta name="x5-page-mode" content="app">
windows phone 点击无高光
<meta name="msapplication-tap-highlight" content="no">
【推荐学习:HTML5视频教程】
以上就是html5怎么禁止横屏的详细内容,更多请关注其它相关文章!
- html5的新特性有哪些
- html5编码怎么设置
声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。