JavascriptË¢ÐÂÒ³ÃæµÄ¼¸ÖÖ·½·¨
JavascriptË¢ÐÂÒ³ÃæµÄ¼¸ÖÖ·½·¨£º
³ÌÐò´úÂë
1 history.go(0)
2 location.reload()
3 location=location
4 location.assign(location)
5 document.execCommand('Refresh')
6 window.navigate(location)
7 location.replace(location)
8 document.URL=location.href
×Ô¶¯Ë¢ÐÂÒ³ÃæµÄ·½·¨:
1.Ò³Ãæ×Ô¶¯Ë¢Ð£º°ÑÈçÏ´úÂë¼ÓÈë<head>ÇøÓòÖÐ
³ÌÐò´úÂë
<meta http-equiv="refresh" content="20">
ÆäÖÐ20ָÿ¸ô20ÃëË¢ÐÂÒ»´ÎÒ³Ãæ.
2.Ò³Ãæ×Ô¶¯Ìøת£º°ÑÈçÏ´úÂë¼ÓÈë<head>ÇøÓòÖÐ
³ÌÐò´úÂë
<meta http-equiv="refresh" content="20;url=http://www.wyxg.com">
ÆäÖÐ20Ö¸¸ô20ÃëºóÌøתµ½http://www.wyxg.comÒ³Ãæ
3.Ò³Ãæ×Ô¶¯Ë¢ÐÂjs°æ
³ÌÐò´úÂë
<script language="JavaScript">
function myrefresh()
{
window.location.reload();
}
setTimeout('myrefresh()',1000); //Ö¸¶¨1ÃëË¢ÐÂÒ»´Î
</script>
JSˢпò¼ÜµÄ½Å±¾Óï¾ä
³ÌÐò´úÂë
//ÈçºÎˢаüº¬¸Ã¿ò¼ÜµÄÒ³ÃæÓÃ
<script language=JavaScript>
parent.location.reload();
</script>
//×Ó´°¿Úˢи¸´°¿Ú
<script language=JavaScript>
self.opener.location.reload();
</script>
(¡¡»ò¡¡<a href="javascript:opener.location.reload()">Ë¢ÐÂ</a> )
//ÈçºÎË¢ÐÂÁíÒ»¸ö¿ò¼ÜµÄÒ³ÃæÓÃ
<script language=JavaScript>
parent.ÁíÒ»FrameID.location.reload();
</script>
Èç¹ûÏë¹Ø±Õ´°¿ÚʱˢлòÕßÏ뿪´°Ê±Ë¢ÐµĻ°£¬ÔÚ<body>Öе÷ÓÃÒÔÏÂÓï¾ä¼´¿É¡£
<body onload="opener.location.reload()"> ¿ª´°Ê±Ë¢ÐÂ
<body onUnload="opener.location.reload()"> ¹Ø±ÕʱˢÐÂ
<script language="javascript">
window.opener.document.location.reload()
Ïà¹ØÎĵµ£º
Ô´´ÓÚ2007Äê12ÔÂ16ÈÕ£¬2009Äê10ÔÂ15ÈÕǨÒÆÖÁ´Ë¡£
°¦£¬ºÜ¾ÃÒÔǰдµÄ´úÂ룬ɹһɹ£¬¹À¼Æ×Ô¼º¿´¶¼¿´²»¶®ÁË£¬:(
var head="display:''"
img_close=new Image()
img_close.src="/sysManage/images/f.gif"
img_open=new Image()
img_open.src="/sysManage/images/fo.gif"
img3=new Image( ......
Ç°Ìì×öµÄÒ³ÃæÊÇÒ»¸öiframeµ¯³ö´°¿Ú£¨ËµÃ÷һϣºÍ¬ÊÂÓÃjs½Å±¾¿ª·¢³öÀ´µÄ£©Àï´¥·¢Ò»¸ö<a>Á´½ÓµÄ°´Å¥¿ÉÔڸô°¿ÚÉϵ¯³öÒ»¸ödivÐü¸¡²ã¡£µ«ÊÇÿ´Îµã»÷£¬divÐü¸¡²ã¾Í×Ô¶¯Î»ÓÚIE´°¿ÚµÄ¶¥¶Ë£¬ÏÂÃæµÄiframe´°¿Ú°üº¬µÄÒ³Ãæ»á×Ô¶¯ÉÏÒÆ£¬Î»ÖôíÂÒÁË¡£
ͬÊÂ˵Ö÷ÒªÊ ......
1£¬¶ÔÏóµÄ¹¹³É
¶ÔÏóÓÐÌØÐÔ¹¹³É(attribute)£¬¿ÉÒÔÊÇÔʼֵ£¬Ò²¿ÉÒÔÊÇÒýÓÃÖµ¡£Èç¹ûÌØÐÔ´æ·ÅµÄÊǺ¯Êý£¬Ëü½«±»¿´×ö¶ÔÏóµÄ·½·¨£¨method£©£¬·ñÔò¸ÃÌØÐÔ±»¿´×öÊôÐÔ£¨property£©¡£
2£¬¶¨ÒåÀà»ò¶ÔÏó
£¨1£©¹¤³§·½Ê½
Code
function createCar(sColor,iDoors) {
&nb ......
1£¬ jsÖеÄÀàÊý×é¶ÔÏó
(1) arguments¶ÔÏó:
function(){
//arguments¶ÔÏóÊÇArguments¶ÔÏóʵÀý£¬ÊÇÒ»¸öÀàÊý×é¶ÔÏ󣬲¢ÓµÓÐÏÂÁз½·¨
alert(arguments instanceof Array);//false
arguments.callee(); //¶Ô×ÔÉíµÄµ÷Ó㬠ÓÃÓڵݹé
var c = arguments.caller; //¶Ôµ÷ÓÃ×ÔÉíº¯ÊýµÄ¸¸º¯Êý, Èç¹û ......