有兴趣的朋友可以看一下这个网页。http://www.interbbs.net/dispbbs.asp?boardID=6&ID=24918&star=3&page=1我们只看网页里面比较大的图片,以第二副为例(就是那张中间有很多队员在庆祝的画面)。查看这副图片的属性,可以看见其链接是http://photos.gznet.com/photos/1142130/1142130-Npa$nMt19b.jpg。但是如果查看整个网页的html代码,可以看见代码里写的是http://photos.gznet.com/photos/1142130/1142130-Npa$nMt19b.jpg,
不难发现,就是把“$”换成了“$”.我用sniffer抓过包,发现IE的请求里确实是http://photos.gznet.com/photos/1142130/1142130-Npa$nMt19b.jpg这个地址。
那么IE是如何知道把网页里的 Npa$nMt19b.jpg 换成 Npa$nMt19b.jpg 这个地址的呢?
这张网页里还有两副图,都是把“$”换成了“$”.呵呵,兴趣问题。无意中发现的。

解决方案 »

  1.   

    HTML代码里面 $=$符号!
      

  2.   

    to  fz_zhou(vcfan):
      你说的  “HTML代码里面 $=$符号” 是对每个网页都如此吗?
      如果是,还有哪些类似的规定?  在哪里可以看见相关的资料?
      谢谢。
      

  3.   

    进来学习呵呵,不知道halk会不会^_^
      

  4.   

    我也没看过,可能是格式化符号,用于输出URL中被作为特殊字符的字符。
    类似于C字符串中,如果你想输出'\'就必须写成'\\'一样。
      

  5.   

    我也很想知道^_^不知道 seventcat(七猫)会不会呵呵
      

  6.   

    我能估计大致的方向,应该是Javascript的一种URL编码。
    我现在想知道的是官方的文档,到底有些什么编码方式?
      

  7.   

    Server.HTMLEncodeAny ASCII code character whose code is greater-than or equal are converted to 0x80 to &#xxx, where xxx is the ASCII character value.
      

  8.   

    ok, crescendo(小青) 解释得很清楚。多问一句,HTMLEncode和urlencode有什么区别?
      

  9.   

    The HTMLEncode method applies HTML encoding to a specified string.The URLEncode method applies URL encoding rules, including escape characters, to a specified string.they are available in MSDN
      

  10.   

    呵呵,刚好这个东西我研究过一段时间的,现在很多是用SCRIPT HOST根据数据库解释出来的
      

  11.   

    找到一个这样的函数:
    function HTMLEncode(fString)
    if not isnull(fString) then
        fString = replace(fString, ">", ">")
        fString = replace(fString, "<", "&lt;")
        fString = Replace(fString, CHR(32), "&nbsp;")
        fString = Replace(fString, CHR(9), "&nbsp;")
        fString = Replace(fString, CHR(34), "&quot;")
        fString = Replace(fString, CHR(39), "&#39;")
        fString = Replace(fString, CHR(13), "")
        fString = Replace(fString, CHR(10) & CHR(10), "</P><P> ")
        fString = Replace(fString, CHR(10), "<BR> ")
        HTMLEncode = fString
    end if
    end function我不懂ASP,但看这代码,应该不只是Any ASCII code character whose code is greater-than or equal are converted to 0x80 to &#xxx, where xxx is the ASCII character value.
      

  12.   

    另外,同样的动网论坛,
    为什么又用“&amp;”代替“&”????
      

  13.   

    &amp;是html中表示&
    &#36;是unicode码吧
      

  14.   

    &开头是转意符,它可以方便表示一些打不出来的特殊符号或一些关键字(为了避免和HTML冲突)如‘<’'>' 等。
      

  15.   

    the regulations are as follows:Server.HTMLEncode
    The HTMLEncode method applies HTML encoding to a specified string. This is useful as a quick method of encoding form data and other client request data before using it in your Web application. Encoding data converts potentially unsafe characters to their HTML-encoded equivalent.If the string to be encoded is not DBCS, HTMLEncode converts characters as follows:The less-than character (<) is converted to &lt;. 
    The greater-than character (>) is converted to &gt;. 
    The ampersand character (&) is converted to &amp;. 
    The double-quote character (") is converted to &quot;. 
    Any ASCII code character whose code is greater-than or equal are converted to 0x80 to &#xxx, where xxx is the ASCII character value. 
    If the string to be encoded is DBCS, HTMLEncode converts characters as follows:All extended characters are converted. 
    Any ASCII code character whose code is greater-than or equal to 0x80 is converted to &#xxx, where xxx is the ASCII character value. 
    Half-width Katakana characters in the Japanese code page are not converted. function HTMLEncode(fString) you put forward is defined by user himself, it's different from Server.HTMLEncode
      

  16.   

    I tried myself."$" is not converted to “&#36;”by Server.HTMLEncode 
    the result you see may use HTMLEncode function defined by the user himself,in which he replace the "$" with "&#36;" hope you can satisfied now 
      

  17.   

    thanks to crescendo(小青——渴望逃跑).我昨天就结贴了。为什么显示不出来?我再想结贴却不行了。