Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

JavascriptÖÐ×î³£ÓõÄ55¸ö¾­µä¼¼ÇÉ£¨×ªÌù£©

 1. oncontextmenu="window.event.returnValue=false" ½«³¹µ×ÆÁ±ÎÊó±êÓÒ¼ü
<table border oncontextmenu=return(false)> <td>no </table> ¿ÉÓÃÓÚTable

2. <body onselectstart="return false"> È¡ÏûÑ¡È¡¡¢·ÀÖ¹¸´ÖÆ

3. onpaste="return false" ²»×¼Õ³Ìù

4. oncopy="return false;" oncut="return false;" ·ÀÖ¹¸´ÖÆ

5. <link rel="Shortcut Icon" href="favicon.ico"> IEµØÖ·À¸Ç°»»³É×Ô¼ºµÄͼ±ê

6. <link rel="Bookmark" href="favicon.ico"> ¿ÉÒÔÔÚÊղؼÐÖÐÏÔʾ³öÄãµÄͼ±ê


7. <input style="ime-mode:disabled"> ¹Ø±ÕÊäÈë·¨


8. ÓÀÔ¶¶¼»á´ø×Å¿ò¼Ü
<script language="JavaScript"> <!--
if (window == top)top.location.href = "frames.htm"; //frames.htmΪ¿ò¼ÜÍøÒ³
// --> </script>


9. ·ÀÖ¹±»ÈËframe
<SCRIPT LANGUAGE=JAVASCRIPT> <!--
if (top.location != self.location)top.location=self.location;
// --> </SCRIPT>


10. ÍøÒ³½«²»Äܱ»Áí´æΪ
<noscript> <*** src="/*.html>"; </***> </noscript>


11. <input type=button value="/²é¿´ÍøÒ³Ô´´úÂë
onclick="window.location = "view-source:"+ "http://www.pconline.com.cn"">
12.ɾ³ýʱȷÈÏ
<a href=""javascript :if(confirm("ȷʵҪɾ³ýÂð?"))location="boos.asp?&areyou=ɾ³ý&page=1"">ɾ³ý </a>


13. È¡µÃ¿Ø¼þµÄ¾ø¶ÔλÖÃ
//Javascript
<script language="Javascript">
function getIE(e){
var t=e.offsetTop;
var l=e.offsetLeft;
while(e=e.offsetParent){
t+=e.offsetTop;
l+=e.offsetLeft;
}
alert("top="+t+"/nleft="+l);
}
</script>
//VBScript
<script language="VBScript"> <!--
function getIE()
dim t,l,a,b
set a=document.all.img1
t=do


Ïà¹ØÎĵµ£º

javascript wrapperº¯Êý

ÔÚÉè¼ÆjavascriptµÄ¼Ì³ÐÌåϵʱ£¬ÓÐÒ»¸öÖØÒªÐèÇ󣬷½·¨Á´¡£Í¨Ë×µØ˵£¬ËµÊÇÔÚ·½·¨Öе÷Óø¸ÀàµÄͬÃû·½·¨¡£ÀàËÆjavaµÄthis.super().method()¡£ÈçºÎ°Ñ¸¸ÀàµÄͬÃû·½·¨°ü×°µ½×ÓÀàÖÐÄØ£¿Õâ¾ÍÒªÓõ½wrapperº¯Êý¡£Ö®ËùÒÔ½Ðwrapper£¬¶ø²»ÊÇwrap£¬ÒòΪËü±Èwrap¸ü¼Ówrapper¡£±ÈÈçÏñExtÄÇÖÖÉî¶È¼Ì³ÐµÄ½á¹¹ÖУ¬Èç¹û¸¸ÀàûÓÐÕÒ×游£¬×æ¸¸Ã»Ó ......

JavaScriptÖض¨Ïò

ʹÓÃJavaScript¿ÉÒÔ½«Óû§µ¼ÏòÒ»¸öÌض¨µÄµØÖ·£¬²¢ÇÒ²»Í¬µÄ·½·¨»á¶Ôä¯ÀÀÆ÷µÄÀúÊ·¼Ç¼Óв»Í¬µÄÓ°Ïì¡£
ʵÀýJavaScript´úÂë
±¾Àý¶¨ÒåÁËÁ½¸öJavaScriptº¯Êý£¬¹¦Äܶ¼ÊÇÖض¨Ïòµ½Ê×Ò³£¬µ«ÊǵÚÒ»¸öº¯Êý²ÉÓõÄÊÇÖ±½Ó¸øhref¸³ÖµµÄ·½Ê½£¬µÚ¶þ¸öʹÓõÄÊÇreplace·½·¨¡£¾ßÌåÇë¿´ÏÂÃæµÄ´úÂ룺
<script type="text/javascript"> fun ......

Google¿ªÔ´JavaScript¹¤¾ß Closure

Google¿ªÔ´ÁËÆäÄÚ²¿Ê¹ÓõÄJavaScript¿ª·¢¹¤¾ßClosure£¬Ï£Íû°ïÖúÍⲿ³ÌÐòÔ±¿ª·¢³öËٶȸü¿ìµÄWebÓ¦ÓóÌÐò¡£GoogleÈÏΪͨ¹ýÔÊÐí¿ª·¢ÕßʹÓÃGoogle×Ô¼ºËùÓõŤ¾ß£¬ËûÃDz»½ö¿ÉÒÔ´´Ôì³ö¸ü¿ìµÄ¸»WebÓ¦ÓóÌÐò£¬¶øÇÒÄÜÕæÕýÈÃWeb²åÉϳá°ò¡£Closure JavaScript±àÒëÆ÷ºÍ¿âÔø±»GoogleÓÃÓÚ¿ª·¢Gmail¡¢Google Docs¡¢Google MapsÒÔ¼°ÆäËüÓ¦Ó ......

JavaScriptµÄeval(¡°{JSON object string}¡±)ÎÊÌâ

ÔÚ×öAJAXÓ¦Óÿª·¢µÄʱºò£¬ÎÒÃÇͨ³£Ï²»¶°Ñ·þÎñÆ÷¶Ë·µ»ØµÄJSON¸ñʽ×Ö·û´®ÔÚ¿Í»§¶ËµÄ»Øµ÷º¯ÊýÖаÑËü×÷ΪJavaScript´úÂëÖ´Ðв¢ÓÃÒ»¸ö±äÁ¿±£´æÆðÀ´£¬ÒÔ·½±ãʹÓ÷µ»ØµÄÊý¾Ý¡£Í¨³£µÄ×ö·¨¾ÍÊÇvar jsonData = eval(xmlHttp.responseText)¡£Õâ¿´ÆðÀ´ËƺõÒ»Çж¼ÊÇÕýÈ·µÄ£¬µ«µ±ÄãÔËÐдúÂëµÄʱºò£¬Äã»á·¢ÏÖ±¨“invalid labe”´ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ