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

javascript ѧϰ±Ê¼Ç£¨1£©

1. javascript ÊÇÇø·Ö´óСдµÄ£¬°üÀ¨±äÁ¿¡¢º¯ÊýÃûµÈµÈ¡£
2. javascript ÖеıäÁ¿ÊÇÈõÀàÐ͵ģ¬¶¨Òå±äÁ¿Ê±Ö»Óà var ÔËËã·û¡£
var test1 = "hi";
»òÕß
var test1 = "hi",test2 = "hello";
»òÕß(¿ÉÒÔÊDz»Í¬µÄÀàÐÍ)
var test1 = "hi",test2 = 12;
»òÕß(¿ÉÒÔ²»Óóõʼ»¯)
var test1;
3. javascript ÿÌõÓï¾äµÄ½áβ“£»”¿ÉÓпÉÎÞ¡£
4. javascript µÄ×¢ÊÍд·¨Óëjava¡¢C¡¢PHP Ò»Ñù¡£
5. javascript ÖГ£û£ý”±íʾ´úÂë¿é¡£
6. javascript ÖеıäÁ¿¿ÉÒÔ“_”¡¢“$”¡¢“×Öĸ”¿ªÍ·¡£
7. javascript ÔÚʹÓñäÁ¿Ê±¿ÉÒÔ²»ÊÂÏÈÉùÃ÷¡£
var test1 = "hello";
test = test1 + " world";
alert(test); //outputs "hello world" 
8. javascript ÌṩÁË typeof ÔËËã·ûÀ´ÅжϱäÁ¿ÀàÐÍ¡£(typeof ¿É¶ÔδÉùÃ÷µÄ±äÁ¿×öÔËËã)
var test = "hello";
alert(typeof test); //outputs "string"
alert(typeof 12); //outputs "number" 
9. null ±íʾÉÐδ´æÔڵĶÔÏó¡£
alert(typeof (null)); //outputs "object" 
10. NaN ±íʾ·ÇÊý£¬Ëü²¢²»µÈÓÚ×ÔÉí¡£
alert(NaN == NaN); //outputs "false" 
alert(isNaN(test)); //outputs "true"
alert(isNaN(12)); //outputs "false" 


Ïà¹ØÎĵµ£º

¸øGridView¼ÓÁ½¸öjavascriptÌØЧ

ÔÚÊý¾Ý°ó¶¨Ê¼þÖÐдÈçÏ´úÂ룺
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row .RowType == DataControlRowType .DataRow)//ÅжÏÊÇ·ñΪÊý¾ÝÐÐ
{
//ÔÚµã»÷ɾ³ýʱ£¬µ¯³öÌáʾ¶Ô»°¿ò
LinkButton lb = e.Row.FindControl("LinkB ......

Javascript DOMѧϰ±Ê¼Ç2


´´½¨ÎĵµÔªËØ
document.createElement(nodename)
²åÈëÔªËص½Îĵµ½ÚµãÊ÷
parent.appendChild(child)
´´½¨Îı¾½Úµã
document.createTextNode(text)
ÔÚÏÖÓÐÔªËØÇ°²åÈëÐÂÔªËØ
parentElement.insertBefore(newElement,targetElement)
ÔÚÏÖÓÐÔªËغó²åÈëÐÂÔªËØ£¨×ԱຯÊý£©
parentElement.insertAfter(newElement,targe ......

Javascript ÅжÏä¯ÀÀÆ÷

                var Sys = {};
                var ua = navigator.userAgent.toLowerCase();
         &nbs ......

Ïêϸ½â¶ÁJavaScriptµÄthis¹Ø¼ü×Ö


ÓÃÁ˺ܾÃJavaScript£¬¶Ô¡¾this¡¿µÄÈÏʶֻ¾ÖÏÞÓÚÒÔÍùµÄƾ¾­Ñé¶øÒÑ£¬²»¹ý½ñÌì·¢ÏÖÁ˺ö«Î÷“http://www.quirksmode.org/js/associative.html”£¬ÏêϸÃèÊöÁËÈçºÎʹÓá¾this¡¿¹Ø¼ü×Ö£¬ÔÚÕâÀïÎҾͼò¶ÌµÄ˵һÏÂÖص㣬Èç¹ûÓÐÒÉÎÊ¿ÉÒÔÖ±½Ó²Î¿¼Ô­ÎÄ¡£
ÔÚѧϰ¹ýÓÐthisµÄ±à³ÌÓïÑÔÖУ¬thisÒ»°ã¶¼ÊÇÖ¸Ïòµ±Ç°ÊµÀý¶ÔÏóµÄ£¬¶ÔÓ ......

³£ÓÃÕýÔò±í´ïʽ,³£ÓÃ±íµ¥ÑéÖ¤javascript´úÂë

function f_MobilCheck(as_SourceString)
{
 if(as_SourceString.match(/^13[0-9]{9}$/g)) return true;  //ÊÖ»úºÅΪ13¿ªÍ·µÄ11λÊý×Ö
 else if(as_SourceString.match(/^[0]{1}[0-9]{2,3}[2-8]{1}[0-9]{5,7}$/g)) return true;¡¡¡¡//СÁéͨΪ0¿ªÍ·µÄ3-4λµÄÇøºÅ£«²»ÒÔ1ºÍ9¿ªÍ·µÄ6£­8λÊý×Ö
 retur ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ