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

Javascript ѧϰ±Ê¼ÇÖ®ÒýÓÃ

ÒýÓÃÊÇÒ»¸öÖ¸Ïò¶ÔÏóʵ¼ÊλÖõÄÖ¸Õë¡£
Àý1£º
var obj = new Object();
var objRef = obj; //objÓëobjRefÖ¸Ïòͬһ¸ö¶ÔÏó,objRefÊÇÒ»¸öÒýÓÃ

×ÔÐ޸ģ¨self-modifying£©
Àý2£º
var items = new Array("one","two","three");
var itemsRef = items; //´´½¨Ò»¸öÒýÓÃ
items.push("four");
alert(items.length == itemsRef.length); //´ËʱÁ½Õß³¤¶ÈÒ»Ö£¬ÒòΪָÏòͬһ¸ö¶ÔÏó

Àý3£º
var items = new Array("one","two","three");
var itemsRef = items;
items = new Array("new"); //´ËʱitemsÓëitemsRefÖ¸Ïò²»Í¬¶ÔÏó

ÔÚÖ´ÐÐ×Ö·û´®Á¬½Ó²Ù×÷ʱ£¬×ÜÊÇ»á²úÉúÒ»¸öеÄ×Ö·û´®¶ÔÏ󣬶ø²»ÊÇÔÚÔ­×Ö·û´®ÉϽøÐиü¸Ä¡£
Àý4£º
var item = "test";
var itemRef = item;
item += "ing";
alert(item != itemRef); //´ËʱitemÓëitemRefÖ¸Ïò²»Í¬¶ÔÏó


Ïà¹ØÎĵµ£º

JavaScript »ñÈ¡¶ÔÏóµÄ¸ß¶ÈºÍ¿í¶ÈÏêϸ˵Ã÷

scrollHeight: »ñÈ¡¶ÔÏóµÄ¹ö¶¯¸ß¶È¡£
scrollLeft:ÉèÖûò»ñȡλÓÚ¶ÔÏó×ó±ß½çºÍ´°¿ÚÖÐĿǰ¿É¼ûÄÚÈݵÄ×î×ó¶ËÖ®¼äµÄ¾àÀë
scrollTop:ÉèÖûò»ñȡλÓÚ¶ÔÏó×î¶¥¶ËºÍ´°¿ÚÖпɼûÄÚÈݵÄ×î¶¥¶ËÖ®¼äµÄ¾àÀë
scrollWidth:»ñÈ¡¶ÔÏóµÄ¹ö¶¯¿í¶È
offsetHeight:»ñÈ¡¶ÔÏóÏà¶ÔÓÚ°æÃæ»òÓɸ¸×ø±ê offsetParent ÊôÐÔÖ¸¶¨µÄ¸¸×ø±êµÄ¸ß¶È
offsetL ......

Îò͸JavaScript Ô­Öø£ºÀîÕ½(leadzen)

Ô­Öø£ºÀîÕ½(leadzen).ÉîÛÚ 2008-2-23
Òý×Ó
    ±à³ÌÊÀ½çÀïÖ»´æÔÚÁ½ÖÖ»ù±¾ÔªËØ£¬Ò»¸öÊÇÊý¾Ý£¬Ò»¸öÊÇ´úÂë¡£±à³ÌÊÀ½ç¾ÍÊÇÔÚÊý¾ÝºÍ´úÂëǧ˿ÍòÂÆµÄ¾À²øÖгÊÏÖ³öÎÞÏÞµÄÉú»úºÍ»îÁ¦¡£
    Êý¾ÝÌìÉú¾ÍÊÇÎľ²µÄ£¬×ÜÏë±£³Ö×Ô¼º¹ÌÓеı¾É«£»¶ø´úÂëÈ´ÌìÉú»îÆÃ£¬×ÜÏë¸Ä±äÕâ¸öÊÀ½ç¡£
  
Äã¿ ......

JavaScriptµÄÈýÖÖ¶Ô»°¿ò

1£ºÖ»ÊÇÌáÐÑ£¬²»ÄܶԽű¾²úÉúÈκθı䣻
2£ºÒ»°ãÓÃÓÚÈ·ÈÏ£¬·µ»Ø true »òÕß false £¬ËùÒÔ¿ÉÒÔÇáËÉÓÃÓÚ if...else...ÅжÏ
3£º Ò»¸ö´øÊäÈëµÄ¶Ô»°¿ò£¬¿ÉÒÔ·µ»ØÓû§ÌîÈëµÄ×Ö·û´®£¬³£¼ûÓÚijЩÁôÑÔ±¾»òÕßÂÛ̳ÊäÈëÄÚÈÝÄÇÀïµÄ ²åÈëUBB¸ñʽͼƬ
<mce:script language="javascript"><!--
function ale()
{//Õâ¸ö»ù±¾Ã»Ó ......

JavaScript Moduleģʽ(ÒëÎÄ)


JavaScript Module Pattern
£¨
JavaScript
Module
ģʽ£© 
À´Ô´£º
1.      
http://yuiblog.com/blog/2007/06/12/module-pattern/
2.      
http://yuiblog.com/blog/2006/06/01/global-domination/
 
È«¾Ö±äÁ¿ÊÇÓкܴóΣº¦µÄ¡£ÔÚ
YU ......

JavaScriptÈëÃÅѧϰÊé¼®µÄ½×¶ÎÑ¡Ôñ


¶ÔÓÚÐí¶àÏëѧϰ JavaScript µÄÅóÓÑÀ´Ëµ£¬ÎÞÒÉÈçºÎÑ¡ÔñÈëÃŵÄÊé¼®ÊÇËûÃÇ×îÍ·ÌÛµÄÎÊÌ⣬»òÐíÒ²ÊÇËûÃÇһֱη¾å£¬ÉõÖÁ·ÅÆúѧϰ JavaScript µÄÀíÓÉ¡£
ÔÚ JavaScript ·½Ã棬×Ô¼º²»ÊÇʲôר¼Ò£¬Ò²²»ÊÇʲô¸ßÊÖ£¬µ«×Ô¼ºÒ»Â·×ßÀ´£¬JavaScript ´ÓÃÔãµ½ÈëµÀ£¬¶ÔÓÚ JavaScript Êé¼®µÄÈÏʶ»òÐí»¹ÓÐЩ½è¼ø¼ÛÖµ¡£
ÈëÃÅÍÆ¼öÊ×Ñ¡Êé¼®£º¡ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ