ÓÐ¹Ø JavaScript µÄ 10 ¼þÈÃÈ˷ѽâµÄÊÂÇé
JavaScript ¿ÉËãÊÇÊÀ½çÉÏ×îÁ÷Ðеıà³ÌÓïÑÔ£¬ËüÔø±» Web ¿ª·¢Éè¼ÆʦÌùÉÏجÃεıêÇ©£¬ËäÈ»ÕæÕýµÄجÃÎÆäʵÊÇ DOM
API£¬Õâ¸ö±»´óÁ¿µÄ¿ª·¢ÓëÉè¼ÆʦËæÊÖÄéÀ´ÔöÇ¿ËûÃÇµÄ Web Ç°¶ËµÄ½Å±¾ÓïÑÔ£¬Èç½ñÔ½À´Ô½±»ÖØÊÓ£¬ËäÔòÈç´Ë£¬JavaScript
ÈÔȻӵÓкܶàÈÃÈ˷ѽâµÄ¶«Î÷¡£
1. ËüÒÔ Java ÃüÃû£¬µ«²¢²»ÊÇ Java
Ëü×î³õ½Ð Mocha£¬ ½ÓןÄÃûΪ LiveScript£¬×îºó²ÅÈ·¶¨ÃüÃûΪ JavaScript£¬¸ù¾ÝÀúÊ·¼Ç¼£¬Java µÄÃüÃûÓë
Netscape ºÍ Sun Ö®¼äµÄºÏ×÷Óйأ¬×÷Ϊ½»»»Ìõ¼þ£¬Netscape ÔÚËûÃDZ¸ÊÜ»¶ÓµÄä¯ÀÀÆ÷Öд´½¨ÁË Java
ÔËÐÐʱ¡£ÖµµÃÒ»ÌáµÄÊÇ£¬Õâ¸öÃû×ֵijǫ̈¼¸½üÒ»¸öÍæЦ£¬ÒªÖªµÀ£¬LiveScript ºÍ Java ÔÚ¿Í»§¶Ë½Å±¾·½Ãæ´æÔڵжԹØϵ¡£
²»¹ÜÔõô˵£¬ÈËÃǺóÀ´²»µÃ²»Ò»ÔÙ³ÎÇåµÄÒ»¼þʾÍÊÇ£¬JavaScript ºÍ Java ºÁÎÞ¹Øϵ¡£
2. Null ÊǸö¶ÔÏó£¿
¿´¿´Õâ¶Î´úÂ룬Ëü·µ»ØµÄÊÇ object¡£
ÕâʵÔÚÁîÈ˷ѽ⣬¼ÙÈç null ±íʾ¿ÕÖµ£¬ËüÔõô¿ÉÒÔÊǶÔÏ󣿼òµ¥Ëµ£¬ËüÊÇ JavaScript ×î³õ°æ±¾µÄ´íÎó£¬Õâ¸ö´íÎóÉõÖÁ±»Î¢ÈíµÄ
JScript Ö±½Ó½èÓá£
3. NaN !== NaN
NaN£¬±íʾһ¸ö·ÇÊý×ÖµÄÖµ£¬È»¶øÎÊÌâÊÇ£¬NaN²»µÈÓÚÈκζ«Î÷£¬ÉõÖÁ²»µÈÓÚËü×Ô¼º¡£
ÕâÏÔÈ»²»¶Ô£¬ÊÂʵÉÏ£¬Èç¹ûÒªÅжÏÒ»¸öֵȷʵÊÇ NaN£¬ÄãÐèÒªÓà isNaN() º¯Êý¡£
4. È«¾Ö±äÁ¿
¶ÔÈ«¾Ö±äÁ¿µÄÒÀÀµÒ»Ö±±»ÊÓΪ JavaScript ×µÄ²¿·Ö£¨ECMA µÄ JavaScript 5 ÒѾȥµôÁËÈ«¾Ö±äÁ¿£¬Çë²ÎÔÄ ECMA
ÍƳö JavaScript 5
- ÒëÕß×¢£©¡£¶Ô¼òµ¥µÄÒ³Ã棬ÕâÎÞËùν£¬µ«¸´ÔÓµÄÒ³Ã棬Èç¹û°üº¬´óÁ¿ JavaScript
½Å±¾£¬ÄãºÜÄÑÖªµÀij¸öÈ«¾Ö±äÁ¿ÊÇÔÚÄÄÀïÉùÃ÷µÄ£¬Èç¹û¼¸¸öÈ«¾Ö±äÁ¿²»Ð¡ÐÄÖØÃû£¬¾Í»áÒý·¢´íÎó¡£
5. ÄÇЩͳͳ±»Ì½²âΪ Mozilla User-Agent µÄä¯ÀÀÆ÷
±ØÐë³ÐÈÏ£¬ÊÂʵÉÏ£¬Õâ²»ÊÇ JavaScript µÄ´í£¬ÊǸ÷¸öä¯ÀÀÆ÷ÓÐÒâΪ֮¡£±ÈÈ磬ÒÔÏÂÊÇÓà JavaScript ̽²â Safari
ʱµÃµ½µÄ½á¹û£º
ÊÇ·ñ×¢Òâµ½ÆäÖеĵÚÒ»¸öµ¥´Ê Mozilla/5.0
£¬ÎªÊ²Ã´ Safari »á±»Ì½²âΪ Mozilla£¬¾¡¹Ü Safari
ºóÀ´ÒѾ¾ÀÕýÕâÒ»ÎÊÌ⣬µ«ÈÔÈ»²»ÄܽâÊÍΪʲôËüÃÇÒªÕâÑùÎ󵼿ª·¢Õß¡£ÊÂʵÉÏ£¬Äã»á·¢ÏÖ£¬¾ø´ó¶àÊýä¯ÀÀÆ÷°ÑËûÃÇµÄ User Agent ÉèÖÃΪ
Mozilla£¬´ð°¸Òª»Øµ½10ÄêÇ°£¬Õâ¸ü¶àÊÇÒ»ÖÖ²ßÂÔ¡£
User Agent ÊÇÒ»¶ÎÓÃÀ´±êʶµ±Ç°ä¯ÀÀÆ÷Éí·ÝµÄ×Ö·û´®£¬ÊÀ½çÉϵÚÒ»¸öä¯ÀÀÆ÷ Mosaic£¬ ÔøÕâÑù±êÖ¾×Ô¼º£º
ÕâºÜºÏÀí£¬Òò´Ëµ± Netscape ³öÀ´µÄʱºò£¬Ëü±£ÁôÁË Mosaic Õâ¸ö´«Í³£¬»¹ÔÚºóÃæÌí¼ÓÁËÒ»¸ö¼ÓÃÜ·½Ê½²¿·Ö¡£
µ½Ä¿Ç°ÎªÖ¹£¬Ò»Çа²ºÃ£¬Ö±µ½ IE3 ·¢²¼£¬µ± IE3 ·¢²¼µÄʱºò£¬N
Ïà¹ØÎĵµ£º
×òÌìÈ¥ÀϼҵÄÊéµêÂòÁ˱¾¡¶JavaScriptÕ÷;¡·£¬Õâ±¾Êé¡£¡£¡£ÄïÄ¡£¡£ÕâÊ黹ÕæËûÂèµÄ¹ó¡£¡£Ô¼Û¡£¡£89.00£¬´òÍêÕÛ»¹ÓÐ80.00ÎÒ²Ù¡£¡£
¿´À´¼ÆËã»úÀàµÄͼÊ黹²»ÊÇÒ»°ãµÄ¼ÛÀà¡£¡£¡£
ÏëÏë¡£¡£¡£×Ô¼º»¹ÓкöàµÄ¼¼ÊõûÓÐѧÍêµÄÀà¡£¡£¡£XHTML£¬CSS£¬JavaScript£¬C#2.0£¬c#3.0.¡£asp.net2.0£¬asp.net3.5
ÏÖÔÚc#ÓÖÒª³ö4.0ÁË¡£¡£¡£ÎÒ ......
ÎÒÃÇÖªµÀ£¬javascriptÔÚÖ´ÐÐÆÚʱÊÇÓÉÄÚµ½ÍâÖ´Ðнű¾µÄ£¬ÄÇôÀëÎÒÃǵĽű¾×îÔ¶µÄÈ«¾Ö¶ÔÏ󣬺ܿÉÄÜÒª¿çÔ½¼¸²ã×÷ÓÃÓò¶ÔÄÜ·ÃÎʵ½Ëü¡£²»¹ýÔÚIEÖУ¬´Ó×îÄڲ㵽×îÍâ²ãÒª»¨µÄʱ¼ä±ÈÆäËû¶à³öºÜ¶à¡£¼ÓÖ®£¬javascriptÊÇÒ»ÖÖ½ºË®ÓïÑÔ£¬Ëü±ØÐëÒªµ÷ÓÃDOM¶ÔÄÜÍê³ÉÎÒÃÇ´ó¶àÊýÑ¡Ôñ¡£×îÖøÃûµÄ¾ÍÊÇÑ¡ÔñÔªËØ£¨document.getElementById,documen ......
ÏÂÃæÊÇÊ®¸ö×îÅ£µÄÒ²ÊÇ×îÁ÷ÐеÄJavascript¿ò¼Ü¡£ËüÃÇÍêÈ«¿ÉÒÔµ£ÈÎÄ¿Ç°ÊÀ½çÉϼ¸ºõËùÓÐһЩºÍAjax¼¼ÊõÏà¹ØµÄºÍͼÐνçÃæÏà¹ØµÄÒ»Çй¦ÄÜ¡£
jQuery
http://jquery.com/
Èç¹û½ñÌìÄ㻹²»ÖªµÀjQueryµÄ»°£¬ÄÇô×÷Ϊһ¸ö³ÌÐòÔ±Äã¿ÉÄÜÕæµÄÊÇ´Ó»ðÐÇÀ´µÄÁË¡£Õâ¿ÖÅÂÊÇAjaxÖÐÓ¦ÓÃ×î¹ãµÄ¿ò¼Ü¡£°üÀ¨ÁËÐí¶àºÜ²»´íµÄUI×é¼þ£¬×ö³öÍø ......
//×Ô´øµÄ´òÓ¡Ô¤ÀÀ WebBrowser.ExecWB(1,1) ´ò¿ª
Web.ExecWB(2,1) ¹Ø±ÕÏÖÔÚËùÓеÄIE´°¿Ú£¬²¢´ò¿ªÒ»¸öд°¿Ú
Web.ExecWB(4,1) ±£´æÍøÒ³
Web.ExecWB(6,1) ´òÓ¡
Web.ExecWB(7,1) ´òÓ¡Ô¤ÀÀ
Web.ExecWB(8,1) ´òÓ¡Ò³ÃæÉèÖÃ
Web.ExecWB(10,1) ²é¿´Ò ......