【发布时间】:2010-12-16 20:39:16
【问题描述】:
运行 .aspx 页面时出现以下错误。
错误码0x8007000d 无法读取配置节“重写”,因为它缺少节声明
我有一个简单的 v.aspx 页面,其中包含以下代码:
Response.Write(Request("q"))
我的托管服务器安装为 IIS 7 并启用了 URL 重写功能(这就是他们声称的)
我的 web.config 文件在下面有以下几行:
注意:节点下方有蓝色波浪线
<rewrite>
<rules>
<rule name="RewriteUserFriendlyURL1" stopProcessing="true">
<match url="^([^/]+)/?$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="v.aspx?q={R:1}" />
</rule>
</rules>
</rewrite>
我已经搜索了stackoverflow,但没有找到解决方案。
可能有人找到了解决方案。
TIA
【问题讨论】:
标签: asp.net iis-7 url-rewriting