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

问个有关问题

2012-01-03 
问个问题.rtunescape(xmlhttp.responseText)rt的内容如下。rtabcdefgwwwdotsohudotcom!DOCTYPEhtmlPUB

问个问题.
rt=unescape(xmlhttp.responseText);
rt的内容如下。
rt   =   "abcdefg   wwwdotsohudotcom  

<!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> <title>
公司抬头
</title> </head>
<body>

我只想定义个变量ss= "abcdefg   wwwdotsohudotcom   "其他的都去掉该怎么做。


[解决办法]
rt = rt.Substring(0,rt.IndexOf( '\r '));
[解决办法]
比如你请求的是x.aspx,把x.aspx中除 <% page ...%> 之外的其他代码全部去掉。
[解决办法]
Response.End()
或者去掉除 <% page ...%> 之外的其他代码。

热点排行