麻烦看一下这段代码,关于htmlencode的,高手来。

来源:百度知道 编辑:UC知道 时间:2024/05/21 09:17:34
<script language="JavaScript" src="script/ViewImage.js"></script>
<%
Response.Write "<table width=100% border=0 align=center bgcolor="&BodyColor&"><tr><td>"&_
"<table><TR><TD align=middle height=10></TD></TR></table>"&_
"<TABLE cellSpacing=1 cellPadding=2 width=90% border=0 align=center>"&_
"<TR><TD height=24 >『"&htmlencode(rs("title"))&"』</TD>"&_
"<TD align=right><A href=""Profile.asp?Action=showdetail&Name="&rs("name")&_
""" target=_blank>"&rs("realname")&"</A> "&rs("uptime")&"</TD>"&_
"</TR>"&_
"<TR><TD colSpan=2 height=23><HR size=1 width=""100%"">图片说明: &

加上
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
Response.ContentType = "text/html"
Response.CharSet = "GB2312"
在所有response的前面,第二行就好
不用htmlencode,换成escape试试

sdfs