在csdn论坛里面,打开一个帖子显示的网址是http://community.csdn.net/Expert/topic/5065/5065393.xml?temp=.1500818
扩展名是.xml,怎莫建立的.xml的网页

解决方案 »

  1.   

    URLRewriter
    http://www.microsoft.com/china/msdn/library/webservices/asp.net/URLRewriting.mspx?mfr=true
    写成XXX.你的名字都没有问题
      

  2.   

    不是把网页转化为xml文件,而是用IO和DOM相关类直接生成xml文档,然后用xsl来控件显示。
      

  3.   

    CSDN是用XML保存网页中的数据,用XSLT把XML转换成网页的你可以看到XSL文件:
    http://community.csdn.net/expert/Xsl/2.xsl
      

  4.   

    一个简单的例子:
    book.xml<?xml version="1.0" encoding="utf-8" ?>
    <?xml-stylesheet type="text/xsl" href="book.xsl"?><books>
    <book>
    <title>Book 1</title>
    <author>Author 1</author>
    </book>
    <book>
    <title>Book 2</title>
    <author>Author 2</author>
    </book>
    </books>book.xsl<?xml version="1.0" encoding="utf-8"?><xsl:stylesheet version="1.0"
        xmlns:xsl="http://www.w3.org/1999/XSL/Transform"><xsl:template match="/">
        <html>
        <body>
    <table border="1">
    <tr>
    <th>Book Name</th>
    <th>Book Author</th>
    </tr>
    <xsl:for-each select="books/book">
    <tr>
    <td>
    <xsl:value-of select="title"/>
    </td>
    <td>
    <xsl:value-of select="author"/>
    </td>
    </tr>
    </xsl:for-each>
    </table>
        </body>
        </html>
    </xsl:template></xsl:stylesheet> 你浏览器打开xml文件即可