首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > JavaScript >

ajax中文乱码有关问题,要求用GB2312

2012-03-29 
ajax中文乱码问题,要求用GB2312!帮我看看乱码怎么回事http://www.avbuyer.com.cn/test/10.htmlhttp://www.

ajax中文乱码问题,要求用GB2312!
帮我看看乱码怎么回事
http://www.avbuyer.com.cn/test/10.html  

http://www.avbuyer.com.cn/test/10_OK.ASP
<%@LANGUAGE= "VBSCRIPT "   CODEPAGE= "936 "%>
<%
Response.ContentType   =   "text/html "
Response.Charset   =   "GB2312 "       '解决乱码问题
    username=request( "username ")
    password=request( "password ")    
        if(username= " "   and   password= " ")   then
            response.Write( "用户名与密码不能为空! ")
        else
if(username= "admin "   and   password= "admin ")   then
response.Write( "登录成功! ")
else
response.Write( "登录失败! ")  
end   if              
end   if              
response.Write(username&password)
%>    


[解决办法]
你的HTML也一样要使用GB2312编码...
[解决办法]
你的HTML也一样要使用GB2312编码...

[解决办法]
unescape()这个函数在服务端好象也可以用,你试试看.
[解决办法]
设置web.config里的字符集为gb2313就可以了

热点排行
Bad Request.