zoukankan      html  css  js  c++  java
  • 浏览器禁止选择

    浏览器禁止选中

    模拟滚动条时可以用

    <!DOCTYPE html>
    <html>
    <head>
        <meta charset=“UTF-8" />
        <title></title>
    </head>
    <style type="text/css">
    .chromeOnselectstart{-webkit-user-select:none;-khtml-user-select:none;-moz-user-select:none;-o-user-select:none;user-select:none;}
    </style>
    <body>
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    试试能选中我不    <br />
    </body>
    <script type="text/javascript">
    if (document.all) {
            //ie 
            document.body.onselectstart = new Function("return false");
        } else {
            document.body.className = "chromeOnselectstart";
        }
    </script>
    </html>
  • 相关阅读:
    12月10日,小雪
    12月10日,小雪
    BUG
    Twenty Hours
    BUG
    07中华小姐大赛落幕 20岁佳丽曾光夺冠
    Twenty Hours
    jeecg 页面标签规则
    jeecg导入备份
    jeecg查询分页
  • 原文地址:https://www.cnblogs.com/qiangspecial/p/2966001.html
Copyright © 2011-2022 走看看