我被迫从出厂默认设备重建我的机器.一切都应该是相同的,IIS版本(7.5),操作系统(Windows 7)和我的网站文件.但是,有些不同,因为在配置我的网站并在我的浏览器中提取本地网站后,我收到以下错误...
HTTP错误500.19 - 内部服务器错误无法访问请求的页面,因为页面的相关配置数据无效.错误代码0x8007000d
当我查找错误代码0x800700d时,它告诉我......
分析:出现此问题的原因是ApplicationHost.config文件或Web.config文件包含格式错误的XML元素.要解决此问题,请参阅解决方案1.
然后提供...的分辨率
建议的解决方案:从ApplicationHost.config文件或Web.config文件中删除格式错误的XML元素.
但是我没有看到格式错误的XML,当我完全删除web.config文件时,网站加载但URL重写不起作用(显然).此外,即使我从web.config文件中删除所有XML,将其留空,我也会收到同样的错误.它似乎存在web.config文件存在的问题.
作为参考,这是我的web.config的内容......
<?xml version="1.0" encoding="UTF-8"?>
<!-- this file can be deleted if you're not planning on using URL rewriting with IIS 7. -->
<!-- you can add your own files and folders that should be excluded from URL rewriting by adding them to the "pattern" below. -->
<!-- please read the online documentation on http://cfwheels.org for more information about URL rewriting. -->
<!-- SET ENABLED TO TRUE BELOW TO TURN ON THE URL REWRITING RULES -->
<configuration>
<system.webServer>
<rewrite>
<rules>
<rule name="ColdFusion on Wheels URL Rewriting" enabled="true">
<match url="^(.*)$" ignoreCase="true" />
<conditions logicalGrouping="MatchAll">
<add input="{SCRIPT_NAME}" negate="true" pattern="^/(flex2gateway|jrunscripts|cfide|cfformgateway|railo-context|files|images|javascripts|miscellaneous|stylesheets|robots.txt|sitemap.xml|rewrite.cfm)($|/.*$)" />
</conditions>
<action type="Rewrite" url="/rewrite.cfm/{R:1}" />
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
Run Code Online (Sandbox Code Playgroud)
有人对如何解决这个问题有任何想法?