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

javaScriptÑéÖ¤´úÂ루Óû§Ãû£¬ÃÜÂ룬ÓÊÏ䣩

<script language="javascript">
function IsDigit(cCheck)
{
return (('0'<=cCheck) && (cCheck<='9'));
}
function IsAlpha(cCheck)
{
return ((('a'<=cCheck) && (cCheck<='z')) || (('A'<=cCheck) && (cCheck<='Z')))
}
function IsaNull(cCheck)
{
return(cCheck != " ")
}
function checkform()
{
id = document.sform1.id.value;
if (id == "")
{
alert("ÇëÊäÈë×¢²áÃû");
document.sform1.id.focus();
return false;
}
for (nIndex=0; nIndex<id.length; nIndex++)
{
cCheck = id.charAt(nIndex);
if (!(IsDigit(cCheck) || IsAlpha(cCheck) || cCheck=='-' || cCheck=='_' || cCheck=='.'))
{
alert("Óû§ÃûÖ»ÄÜʹÓÃ×Öĸ¡¢Êý×ÖÒÔ¼°-¡¢_ºÍ.£¬²¢ÇÒ²»ÄÜʹÓÃÖÐÎÄ");
document.sform1.id.focus();
return false;
}
}
chineseid = document.sform1.chineseid.value;
if (chineseid == "")
{
alert("ÇëÊäÈëÖÐÎÄêdzÆ");
document.sform1.chineseid.focus();
return false;
}
password = document.sform1.password.value;
if (password == "")
{
alert("ÇëÊäÈëµÇ½ÃÜÂë");
document.sform1.password.focus();
return false;
}
password1 = document.sform1.password1.value;
if (password>password1)
{
alert("Öظ´ÃÜÂëÓëµÇ½ÃÜÂë²»Ïàͬ");
document.sform1.password.focus();
document.sform1.password1.focus();
return false;
}
if (password<password1)
{
alert("Öظ´ÃÜÂëÓëµÇ½ÃÜÂë²»Ïàͬ");
document.sform1.password.focus();
document.sform1.password1.focus();
return false;
}
if (document.sform1.email.value == "")
{
alert("ÇëÊäÈëÄúµÄE-MAILµØÖ·");
document.sform1.email.focus();
return false;
}
email=document.sform1.email.value;
emailerr=0
for (i=0; i<email.length; i++)
{
if ((email.charAt(i) == "@") & (email.length > 5))
{
emailerr=emailerr+1
}
}
if (emailerr != 1)
{
alert("ÇëÊäÈëÕýÈ·µÄE-MAILµØÖ·");
document.sform1.email.focus();
return false;
}
if (document.sform1.checkask.value=="")
{
alert("ÃÜÂëÌáʾÎÊÌâ²»ÄÜΪ¿Õ");
document.sform1.checkask


Ïà¹ØÎĵµ£º

ÓÃJavaScriptдµÄСʱºòÍæµÄƹÅÒÇòСÓÎÏ·

ÓÉÓÚ»ðºüä¯ÀÀÆ÷²»Ö§³Ö“removeNode”º¯Êý£¬ËùÒÔһϴúÂëÖ»Ö§³ÖIE.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
< ......

javascript prototype½éÉܵÄÎÄÕÂ

JavaScriptÊÇ»ùÓÚ¶ÔÏóµÄ£¬ÈκÎÔªËض¼¿ÉÒÔ¿´³É¶ÔÏó¡£È»¶ø£¬ÀàÐͺͶÔÏóÊDz»Í¬µÄ¡£±¾ÎÄÖУ¬ÎÒÃdzýÁËÌÖÂÛÀàÐͺͶÔÏóµÄһЩÌصãÖ®Í⣬¸üÖØÒªµÄÊÇÑо¿ÈçºÎд³öºÃµÄ²¢ÇÒÀûÓÚÖØÓõÄÀàÐÍ¡£±Ï¾¹£¬JavaScriptÕâÖÖÁ÷ÐеĽű¾ÓïÑÔÈç¹ûÄܹ»½øÐÐÁ¼ºÃµÄ·â×°£¬²¢ÐγÉÒ»¸öÅÓ´óµÄÀàÐͿ⣬¶ÔÓÚÖØÓÃÊǷdz£ÓÐÒâÒåµÄ¡£
ÍøÉ϶ÔÓÚprototypeµÄÎÄÕ弆 ......

Javascript ʹÓÃIDE¹¤¾ß½øÐе÷ÊÔ

1. Javascript Debug Toolkit½éÉÜ
JSDT(Javascript Debug Toolkit)ÊÇÒ»¸öÓÃÓÚjavascriptµ÷ÊÔµÄeclipse
²å¼þ£¬ÓÃÓÚµ÷ÊÔjavascript¡£JSDT¿ÉÒÔ¿çä¯ÀÀÆ÷µ÷ÊÔ£¬Ö§³ÖÔÚIE,Firefox,Safari,ChromeµÈÖ÷Á÷ä¯ÀÀÆ÷Öе÷ÊÔ
javascript¡£JSDTÖ§³ÖÉèÖöϵ㣬µ¥²½µ÷ÊԵȵ÷ÊÔ¹¤¾ßµÄ»ù±¾ÌØÐÔ¡£
2. ÈçºÎ°²×°
JSDTÊÇ»ùÓÚeclipse3.2+,jdk1.5+ ......

javascriptдÔÚº¯ÊýÀïÃæ

javascriptдÔÚº¯ÊýÀïÃæ
function loadscript(url) {
document.write('<scr' + 'ipt  type="text/javascript" src"' + url + '"><\/scr' + 'ipt>'>)
}
Ôڳɹ¦µÄÕýÔò±í´ïʽ²éÕÒÍê³É֮ǰ£¬ÆäÊôÐÔֵΪ undefined¡£
²»Òª½«È«¾Ö RegExp ¶ÔÏóÓë ÕýÔò±í´ïʽ
¶ÔÏó»ìÏý¡£¾¡¹ÜÌýÆðÀ´Ï ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ