阿里云服务器免费领卷啦。

捡代码论坛-最全的游戏源码下载技术网站!

 找回密码
 立 即 注 册

QQ登录

只需一步,快速开始

搜索
关于源码区的附件失效或欺骗帖, 处理办法
查看: 2042|回复: 0

禁用各种网页限制,包含右键,复制,选择文字。

[复制链接]

4208

主题

210

回帖

12万

积分

管理员

管理员

Rank: 9Rank: 9Rank: 9

积分
126213
QQ
发表于 2016-5-24 19:08:13 | 显示全部楼层 |阅读模式
  1. // ==UserScript==
  2. // @name                        Anti Disabler For All
  3. // @description                禁用各种网页限制,包含右键,复制,选择文字。
  4. // @namespace   b8a2c97204b09fc19cf99340f5fae276
  5. // @include                        *
  6. // @exclude                        http*://mail.google.com/*
  7. // @exclude                        http://maps.google.com/*
  8. // @author                        ejin
  9. // @version                        2013.09.08
  10. // ==/UserScript==

  11. function restore(){
  12. with (document.wrappedJSObject || document) {
  13. onmouseup = null;
  14. onmousedown = null;
  15. oncontextmenu = null;

  16. // *
  17. onselectstart = null
  18. onbeforecopy = null
  19. onkeydown = null
  20. onkeydown = null

  21. }

  22. // *
  23. void(document.body.onmouseup='');
  24. void(document.body.onselectstart='');
  25. void(document.body.onmouseup='');
  26. void(document.body.oncopy='');

  27. var arAllElements = document.getElementsByTagName('*');
  28. for (var i = arAllElements.length - 1; i >= 0; i--) {
  29. var elmOne = arAllElements[i];
  30. with (elmOne.wrappedJSObject || elmOne) {
  31. onmouseup = null;
  32. onmousedown = null;
  33. }
  34. }
  35. }

  36. window.addEventListener('load',restore,true);

  37. function addGlobalStyle(css) {
  38.     var head, style;
  39.     head = document.getElementsByTagName('head')[0];
  40.     if (!head) { return; }
  41.     style = document.createElement('style');
  42.     style.type = 'text/css';
  43.     style.innerHTML = css;
  44.     head.appendChild(style);
  45. }

  46. addGlobalStyle("html, * {-moz-user-select:text!important;}");
复制代码



捡代码论坛-最全的游戏源码下载技术网站! - 论坛版权郑重声明:
1、本主题所有言论和图片纯属会员个人意见,与本论坛立场无关
2、本站所有主题由该帖子作者发表,该帖子作者与捡代码论坛-最全的游戏源码下载技术网站!享有帖子相关版权
3、捡代码论坛版权,详细了解请点击。
4、本站所有内容均由互联网收集整理、网友上传,并且以计算机技术研究交流为目的,仅供大家参考、学习,不存在任何商业目的与商业用途。
5、若您需要商业运营或用于其他商业活动,请您购买正版授权并合法使用。 我们不承担任何技术及版权问题,且不对任何资源负法律责任。
6、如无法链接失效或侵犯版权,请给我们来信:jiandaima@foxmail.com

回复

使用道具 举报

*滑块验证:
您需要登录后才可以回帖 登录 | 立 即 注 册

本版积分规则

技术支持
在线咨询
QQ咨询
3351529868

QQ|手机版|小黑屋|捡代码论坛-专业源码分享下载 ( 陕ICP备15015195号-1|网站地图

GMT+8, 2024-5-7 11:02

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表