日期:2014-05-17  浏览次数:20886 次

初学者问题
在b.asp中,接收了从   a.asp的数据
dim     yourName
yourName=trim(Request.Form( "userName "))
我想在b.asp中用alert是显示出“你的名子是XXX”(X为收到数据)
我写了以下句子:
〈%
              response.write " <SCRIPT   language=JavaScript> "
response.write "alert( '您输入的验证码不正确。 '+yourName); "
response.write "location.href= 'login.asp ' </SCRIPT> "
%〉
但发现这个变量yourName是在服务器端,在客户端无法显示,而且一个是VBScritp
一个是jscript,请问如何解决?

------解决方案--------------------
response.write "alert( '您输入的验证码不正确。 ' "&yourName& "); "
------解决方案--------------------
response.write( "alert( '您输入的验证码不正确。 ' "& yourName & "); ")