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

javascript check all and uncheck

<script language='javascript'>
function toggleAll(cb)
{
    var val = cb.checked;
    var frm = document.forms[0];
    var len = frm.elements.length;
    var i=0;
    for( i=0 ; i<len ; i++)
    {
        if (frm.elements[i].type=="checkbox" && frm.elements[i]!=cb)
        {
            frm.elements[i].checked=val;
        }
    }
}
</script>
//Sample Usage
<form >
Check ALL
<input type="checkbox" name="checkall" onclick="toggleAll(this)" id="Checkbox1" />
<br>
<input type="checkbox" name="check1" id="Checkbox2" />
<input type="checkbox" name="check2" id="Checkbox3" />
<input type="checkbox" name="check3" id="Checkbox4" />
<input type="checkbox" name="check4" id="Checkbox5" />
<input type="checkbox" name="check5" id="Checkbox6" />
</form>


Ïà¹ØÎĵµ£º

javascriptЧÂʾ­Ñé̸(Ò»)

±¾ÎÄÖ÷ÒªÊdzöÓÚÓÐÅóÓÑʹÓÃÎÒÔ­À´Ð´µÄautocompleteµÄJS¿Ø¼þ¡£µ±Êý¾ÝÁ¿´óµÄʱºò£¬»á³öÏÖЧÂʼ«ÆäÂýµÄÇé¿ö£¬ÎÒÔÚÕâ¶Îʱ¼ä×ö³öµÄһЩ²âÊÔÒ²¼°Ò»Ð©¾­Ñ飬Óë´ó¼Ò·ÖÏí£¬Èç¹ûÓдíµÄµØ·½£¬»¹ÇëÖ¸³ö¡£
¾­¹ý²âÊÔ£¬ÎÒÃǻᷢÏÖÈçϵÄÇé¿ö»òÕß˵µÄ½áÂÛ£¬Èç¹ûÄúµÄ²âÊÔ½á¹ûÓëÎҵIJ»·û£¬Çë˵Ã÷Ô­Òò£¬ÒÔ±ãÏ໥ѧϰ¡£
1£©µ±Ò»¸ö½Ï´óµÄHTML×Ö· ......

JavaScript ¹¹Ô캯Êý myhere

/**
* JavaScript ÊÇÃæÏò¶ÔÏóµÄÓïÑÔ£¬µ«ÊÇËûµÄÃæÏò¶ÔÏó²»ÊÇ»ùÓÚÀàµÄ£¬ÊÇ»ùÓÚÔ­Ð͵Ä;
* µ«ÊÇËûµÄÒ»Ð©ÌØÐÔ(º¯ÊýÊÇÊý¾Ý)£¬Ê¹µÃËü¿ÉÒÔÄ£Äâ»ùÓÚÀàµÄÃæÏò¶ÔÏ󣬵«ÊÇ JavaScript ²¢²»Ö§³ÖºÍ Java Ò»ÑùµÄÀ࣬
* Òò´Ë JavaScript ÖеÄ"Àà"¿ÉÒÔ³Æ×÷"αÀà"
*/
//
/**
* ¹¹Ô캯Êý: js ÖÐÓÃÀ´ºÍ new ÔËËã·ûÒ»ÆðʹÓõĺ¯Êý³Æ× ......

javascript³£ÓÃ

calcu()  ----º¯ÊýʵÏÖÁ½¸öÊýÏà³Ë
document.write();  ---´òÓ¡
document.calc.ÔªËØÃû.value;  --»ñµÃ±íµ¥µÄÖµ
document.±íµ¥Ãû¡£±íµ¥ÔªËØÃû¡£value  Ϊ±íµ¥¸³Öµ
¶¨Ò庯Êý£º
 function  Ãû×Ö()
 {
    //javaScriptÔ¤Óï¾ä
 }
 onClick="º¯ÊýÃû";  ......

javascript calendar

<SCRIPT>
//ÅжÏyÄêµÄÅ©ÀúÖÐÄǸöÔÂÊÇÈòÔÂ,²»ÊÇÈòÔ·µ»Ø0
function leapMonth(y){
return(lunarInfo[y-1900]&0xf);
}
var lunarInfo=new Array(
0x04bd8,0x04ae0,0x0a570,0x054d5,0x0d260,0x0d950,0x16554,0x056a0,0x09ad0,0x055d2,
0x04ae0,0x0a5b6,0x0a4d0,0x0d250,0x1d255,0x0b540,0x0d6a0,0x0ada2,0 ......

javascriptдÀ෽ʽ֮һ

´ÓÕâÆªÆð£¬»áÓÉdzµ½ÉîµÄ·ÖÎöjs OO֮дÀ෽ʽ£¬´ó¸Å»áÓÐ5-8ƪ¡£ºóÃæÂ½Ðø»á·ÖÎöÁ÷Ðп⣨¿ò¼Ü£©µÄдÀ෽ʽ¡£ÎªÁËÌÖÂ۵ĵ¥Ò»ÐÔ£¬Ôݲ»¿¼ÂÇÀàµÄ¼Ì³Ð£¬(˽ÓÐ,Êܱ£»¤)ÊôÐÔ»ò·½·¨¡£
EMCA262¹æ·¶ÖÐûÓÐÀà(class)µÄ¸ÅÄjsµÄnewÖ»ÊÇÈÃËû¿´ÆðÀ´¸üÏñc++,javaÒ»µã¡£ÕâÀï˵µÄдÀֻ࣬ÊÇÊéдjs´úÂë·ç¸ñ¶øÒÑ¡£
1¡¢¹¹Ô캯Êý·½Ê½
/**
* P ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ