JavaScript ÅжÏÉÏ´«ÎļþÀàÐÍ
function
Check_FileType(str)
{
var
pos
=
str.lastIndexOf(
"
.
"
);
var
lastname
=
str.substring(pos,str.length) //´Ë´¦Îļþºó׺ÃûÒ²¿ÉÓÃÊý×鷽ʽ»ñµÃstr.split(".")
if
(lastname.toLowerCase()
!=
"
.jpg
"
&&
lastname.toLowerCase()
!=
"
.gif
"
)
{
alert(
"
ÄúÉÏ´«µÄÎļþÀàÐÍΪ
"
+
lastname
+
"
£¬Í¼Æ¬±ØÐëΪ.jpg,.gifÀàÐÍ
"
);
document.myform.pic.focus();
return
false
;
}
else
{
return
true
;
}
}
http://www.cnblogs.com/SList/archive/2005/11/09/272164.html
Ïà¹ØÎĵµ£º
JScript ÔËÐÐʱ´íÎó
¡¡¡¡JScript ÔËÐÐʱ´íÎóÊÇÖ¸µ± JScript ½Å±¾ÊÔͼִÐÐÒ»¸öϵͳ²»ÄÜÔËÐе͝×÷ʱµ¼ÖµĴíÎó¡£µ±ÕýÔÚÔËÐнű¾¡¢¼ÆËã±äÁ¿±í´ïʽ¡¢»òÕßÕýÔÚ¶¯Ì¬·ÖÅäÄÚ´æÊ±³öÏÖ JScript ÔËÐÐʱ´íÎóʱ¡£
´íÎóºÅ ÃèÊö
5029 Êý×鳤¶È±ØÐëΪһÓÐÏÞÕýÕûÊý
5030 ±ØÐ븳¸øÊý×鳤¶ÈÒ»¸öÓÐÏÞÕýÊý
5028 ÐèÒª Array »ò arguments ......
µÚÒ»ÖÖ:
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>ÎÞ±êÌâÎ ......
js¶ÔÎÄ×Ö½øÐбàÂëÉæ¼°3¸öº¯Êý£ºescape,encodeURI,encodeURIComponent£¬ÏàÓ¦3¸ö½âÂ뺯Êý£ºunescape,decodeURI,decodeURIComponent
1¡¢ ´«µÝ²ÎÊýʱÐèҪʹÓÃencodeURIComponent£¬ÕâÑù×éºÏµÄurl²Å²»»á±»#µÈÌØÊâ×Ö·û½Ø¶Ï¡£ ......
ÉùÃ÷£º±¾ÎÄϵJavaEyeÍøÕ¾·¢²¼µÄÔ´´²©¿ÍÎÄÕ£¬Î´¾×÷ÕßÊéÃæÐí¿É£¬ÑϽûÈκÎÍøÕ¾×ªÔØ±¾ÎÄ£¬·ñÔò±Ø½«×·¾¿·¨ÂÉÔðÈΣ¡
ʵÏÖiframeÄÚ²¿Ò³ÃæÖ±½Óµ÷ÓøÃiframeËùÊô¸¸´°¿Ú×Ô¶¨Ò庯ÊýµÄ·½·¨¡£
±ÈÈçÓÐA´°¿Ú£¬AÄÚÓиöIFRAME. B£¬BÀïÃæµÄ×°ÔØµÄÊÇCÒ³Ãæ£¬ÕâʱCÒªÖ±½Óµ÷ÓÃAÀïÃæµÄÒ»¸ö×Ô¶¨Ò庯ÊýExpandPage();
ÄÇôֻҪÔÚCÒ³ÃæÖÐдÈçÏÂJ ......
Struts Validator Framework provides an easy-to-use mechanism for performing client-side validation. It's very useful to validate some fields on the client-side before sending the data to the server for processing. By this way we can ensure that the data send to the server is valid. Performing valida ......