建議:ASP程式設計中15個非常有用的例子(二) 8.強迫輸入密碼對話框答把這句話放載頁面的開頭% response.status=401 not Authorized response.end % 9 如何傳遞變數從一頁到另一頁答用HIDDEN類型來傳遞變數% form method =post action=mynextpage.asp % for each item in request.form % input
function isCharsInBag (s, bag){
var i,c;
for (i = 0; i < s.length; i++)
{
c = s.charAt(i);//字串s中的字符
if (bag.indexOf(c) > -1)
return c;
}
return ;
}
檢查函數:
function ischinese(s)
{
var errorChar;
var badChar = ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789><,[]{}?/+=|//'/:;~!#$%()`;
errorChar = isCharsInBag( s, badChar)
if (errorChar != )
{
report=report+請重新輸入中文/n;
return false;
}
return true;
}
分享:ASP程式設計中15個非常有用的例子(一) 1.如何用Asp判斷你的網站的虛擬物理路徑答使用Mappath方法p align=centerfont size=4 face=Arialb The Physical path to this virtual website is: /b/font font color=#FF0000 size=6 face= Arial %= Server.MapPath(/)% /font/p 2.我如何