Bookmark and Share

Lee's 程序人生

HTML CSS Javascript XML AJAX ATLAS C# C++ 数据结构 软件工程 设计模式 asp.net Java 数字图象处理 Sql 数据库
  博客园  :: 首页  :: 新随笔  :: 联系 :: 管理

Firefox 禁止选择,屏蔽右键

Posted on 2008-06-13 10:19  analyzer  阅读(1786)  评论(0)    收藏  举报
<!--  
  document.oncontextmenu=function(e){return   false;}  
  //-->  
  </script>  
  <style>  
  body   {  
    -moz-user-select : none;  
  }  
  </style>  
  <body   onselectstart="return   false">  
  asdfasdfsadfasdfasdfasdfasfsadfsdf  
  </body>

 

函数解释:

 

语 法很简单: CSS中加入 html, * { -moz-user-select:none } (FireFIX专用CSS属性)即可。 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title> - http://www.never-online.net </title> <meta http-equiv="ImageToolbar" content="no" /> <meta name="author" content="never-online, BlueDestiny"/> <meta name="keywords" content="never modules, Mozilla CSS, C#, .net, Reference, <a title="" href="http://blog.csdn.net/BlueDestiny" _f

onselectstart="return false"      禁止复制的

 


 document.oncontextmenu=function(e){return   false;}   防止点右键出现菜单