javascript ÅжÏÎļþÀàÐÍ
function checkfiletype()
{
var fileName = document.getElementById('<%=FilePath.ClientID%>').value;
if (Trim(fileName)=="")
{
alert("ÇëÑ¡ÔñÒªÉÏ´«µÄÎļþ£¡");
document.getElementById('<%=FilePath.ClientID%>').focus();
return false;
}
//ÉèÖÃÎļþÀàÐÍÊý×é
var extArray = new Array(".rar",".doc",".rtf",".xls");
//»ñÈ¡ÎļþÃû³Æ
while (fileName.indexOf("\\") != -1)
fileName = fileName.slice(fileName.indexOf("\\") + 1);
//»ñÈ¡ÎļþÀ©Õ¹Ãû
var ext = fileName.slice(fileName.indexOf(".")).toLowerCase();
//±éÀúÎļþÀàÐÍ
for (var i = 0; i < extArray.length; i++)
{
if (extArray[i] == ext)
{
return true;
}
}
alert("Ö»ÄÜÉÏ´«ÏÂÁÐÀàÐ͵ÄÎļþ: " + extArray.join(" "));
document.getElementById('<%=FilePath.ClientID%>').focus();
return false;
}
Ïà¹ØÎĵµ£º
label:statement
Àý£º
start:var iCount = 10;
±êÇ©¿ÉÒÔ±»ºóÀ´µÄbreakÓï¾ä»òcontinueÓï¾äÒýÓá£
Àý£º
var iNum=0;
outermost:
&n ......
ÒýÓÃÀàÐÍͨ³£½Ð×öÀࣨclass£©£¬Óöµ½ÒýÓÃֵʱ£¬Ëù´¦ÀíµÄ¾ÍÊǶÔÏó¡£
¶ÔÏóµÄ´´½¨£º
var o = new Object();
Èç¹ûûÓвÎÊý¿ÉÒÔÊ¡ÂÔÀ¨ºÅ£¬È磺var o = new Object;
ObjectÀࣺ
&nb ......
JavaScript ÊÇÒ»¿îÇ¿´óµÄ¹ã·ºÔËÓÃÓÚÏÖ´úWebÕ¾µã¼°Ó¦ÓõĽű¾ÓïÑÔ¡£×÷Ϊһ¸ö¼¼ÒÕ¾«Õ¿µÄ Web ¿ª·¢Õߣ¬ÕÆÎÕJavaScript¿ÉÒÔÔöÇ¿Óû§µÄʹÓÃÌåÑ飬Ìṩ½»»¥¼°¸»¿Í»§¶ËµÈ¹¦ÄÜ¡£
¾¡¹ÜJavaScript µÄÓï·¨·Ç³£¼òµ¥£¬µ«¶ÔÓÚд³ÌÐò¶øÑÔÈÔÈ»ÊÇÀ§ÄÑÖØÖØ£¬¾ÍÊÇÒòΪËüµÄÔËÐл·¾³£º»ùÓÚWebä¯ÀÀÆ÷¡£
ÒÔÏÂÄú¿ÉÒÔ¿´µ½ÊÕ¼¯µÄ8¸öʵÓÃµÄ JavaScr ......
50¸öʵÓõÄJavaScript¹¤¾ß- - JavaEye¼¼ÊõÍøÕ¾
JavaScriptÊÇÒ»¸ö¹¦ÄÜÇ¿´óµÄ¿Í»§¶Ë½Å±¾ÓïÑÔ£¬Ðí¶àÏÖ´ú»¯µÄÍøÕ¾ºÍWebÓ¦ÓóÌÐò¶¼»áʹÓõ½Ëü¡£JavaScript¿ÉÒÔÔöÇ¿Óû§µÄÌåÑ飬²¢Ìṩ·á¸»µÄ»¥¶¯Ê½×é¼þºÍ¹¦ÄÜ¡£ËäÈ»ËüµÄÓï·¨Ï൱¼òµ¥£¬µ«ÊǶԿª·¢ÕßÀ´Ëµ»¹ÊǺÜÓÐÄѶȵģ¬ÒòΪËüÒªÔËÐÐÔÚWebä¯ÀÀÆ÷ÖС£
¡¡¡¡ÒÔÏÂÊÇÎÒÃÇΪÄãÍÆ¼öµÄ50¸ ......
ShowModalDialogº¯ÊýµÄ¹¦ÄÜ£º
´ò¿ªÒ»¸ö×Ó´°¿Ú£¬²¢ÇÒ¿ÉÓ븸´°¿ÚÏ໥´«µÝÊý¾Ý£¬ËüÓëwindow.openµÄ×î´óÇø±ð¾ÍÔÚÓÚÓÉShowModalDialog´ò¿ª×Ó´°¿Úºó£¬¸¸´°¿Ú½«²»ÄܲÙ×÷¡£
ʹÓ÷½·¨£º
vReturnValue = window.showModalDialog(sURL [, vArguments] [, sFeatures])
²ÎÊý˵Ã÷£º
sURL
±ØÑ¡²ÎÊý£¬ÀàÐÍ£º×Ö·û´®¡£ÓÃÀ´Ö¸¶¨¶Ô»°¿òÒªÏ ......