Discuz!官方免费开源建站系统

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索

[求助] IIS 7 规则配置问题

[复制链接]
豪杰鸿飞 发表于 2012-4-17 10:52:51 | 显示全部楼层 |阅读模式
本帖最后由 豪杰鸿飞 于 2012-4-17 17:47 编辑

我的网站是http://www.you1234.cn/我用二级目录建了一个论坛,http://www.you1234.cn/bbs   现在问题是直接访问出现500错误,访问 http://www.you1234.cn/bbs/forum.php可以打开。我的web.config配置是
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <configuration>
  3. <system.webServer>
  4. <defaultDocument>
  5. <files>
  6. <add value="index.php" />
  7. </files>
  8. </defaultDocument>
  9. <rewrite>
  10. <rules>
  11. <rule name="Imported Rule 1">
  12. <match url="^topic-(.+)\.html$" ignoreCase="false" />
  13. <action type="Rewrite" url="portal.php?mod=topic&topic={R:1}" appendQueryString="false" />
  14. </rule>
  15. <rule name="Imported Rule 2">
  16. <match url="^article-([0-9]+)\.html$" ignoreCase="false" />
  17. <action type="Rewrite" url="portal.php?mod=article&articleid={R:1}" appendQueryString="false" />
  18. </rule>
  19. <rule name="Imported Rule 3">
  20. <match url="^forum-(\w+)-([0-9]+)\.html$" ignoreCase="false" />
  21. <action type="Rewrite" url="forum.php?mod=forumdisplay&fid={R:1}&page={R:2}" appendQueryString="false" />
  22. </rule>
  23. <rule name="Imported Rule 4">
  24. <match url="^thread-([0-9]+)-([0-9]+)-([0-9]+)\.html$" ignoreCase="false" />
  25. <action type="Rewrite" url="forum.php?mod=viewthread&tid={R:1}&extra=page\%3D{R:3}&page={R:2}" appendQueryString="false" />
  26. </rule>
  27. <rule name="Imported Rule 5">
  28. <match url="^group-([0-9]+)-([0-9]+)\.html$" ignoreCase="false" />
  29. <action type="Rewrite" url="forum.php?mod=group&fid={R:1}&page={R:2}" appendQueryString="false" />
  30. </rule>
  31. <rule name="Imported Rule 6">
  32. <match url="^space-(username|uid)-(.+)\.html$" ignoreCase="false" />
  33. <action type="Rewrite" url="home.php?mod=space&{R:1}={R:2}" appendQueryString="false" />
  34. </rule>
  35. <rule name="Imported Rule 7">
  36. <match url="^([a-z]+)-(.+)\.html$" ignoreCase="false" />
  37. <action type="Rewrite" url="{R:1}.php?rewrite={R:2}" appendQueryString="false" />
  38. </rule>
  39. </rules>
  40. </rewrite>
  41. <httpRedirect enabled="false" destination="http://www.you1234.cn/bbs" exactDestination="false" httpResponseStatus="Permanent" />

  42. </system.webServer>
  43. </configuration>
复制代码
问题是:
配置错误在唯一密钥属性“value”设置为“index.php”时,无法添加类型为“add”的重复集合项
请高手相助~
 发表于 2012-4-17 13:30:31
转播微博[tthread=dongdong1403, 中国Sx丶东哥]http://app.qlogo.cn/mbloghead/9bfee63c93a196fc28a6[/tthread]
回复

使用道具

 楼主| 豪杰鸿飞 发表于 2012-4-17 13:48:10 | 显示全部楼层
我在线等……谢谢!
回复

使用道具 举报

crx349 发表于 2012-4-17 15:35:37 | 显示全部楼层

回帖奖励 +10 枚金币

<defaultDocument>
<files>
<add value="forum.php" />
</files>
</defaultDocument>

这段去掉
回复

使用道具 举报

 楼主| 豪杰鸿飞 发表于 2012-4-17 17:48:05 | 显示全部楼层
crx349 发表于 2012-4-17 15:35
这段去掉

去掉也没有用的
回复

使用道具 举报

 楼主| 豪杰鸿飞 发表于 2012-4-17 22:11:14 | 显示全部楼层
还有高手吗?急~
回复

使用道具 举报

crx349 发表于 2012-4-18 09:08:05 | 显示全部楼层
改 net2 的集成模式看看
回复

使用道具 举报

xiaoyuwxz 发表于 2012-4-20 11:13:45 | 显示全部楼层
把规则的开头改成^bbs/ 开头
回复

使用道具 举报

12153556 发表于 2012-4-20 20:46:24 | 显示全部楼层
开启父路径了吗?
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

手机版|小黑屋|Discuz! 官方站 ( 皖ICP备16010102号 )star

GMT+8, 2024-4-24 21:59 , Processed in 0.439579 second(s), 17 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回复 返回顶部 返回列表