今天有个哥们要用THINKSNS这个系统,但是他的系统是iis7.0的,把伪静态规则放到下边不管用,很纠结,找到了我,然后让我帮忙重写下伪静态,他的伪静态我们有重写,但是我修改了一下现在可以用了,然后放出来给大家!
<?xml version="1.0" encoding="UTF-8"?>
<configuration>
<system.webServer>
<httpRedirect enabled="true" />
<rewrite>
<rules>
<clear />
<rule name="url">
<match url="^/?url/([a-zA-Z0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="shorturl.php?url={R:1}" />
</rule>
<rule name="?rewrite">
<match url="^/?rewrite$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="public/rewrite.php" />
</rule>
<rule name="?page">
<match url="^/?page/([0-9a-zA-Z_]+)\.html$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=page&mod=Index&act=index&page={R:1}&%{QUERY_STRING}" />
</rule>
<rule name="?home">
<match url="^/?home$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Index&act=index&%{QUERY_STRING}" />
</rule>
<rule name="?public_profile">
<match url="^/?@([_a-zA-Z0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Profile&act=index&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="?profile">
<match url="^/?@([0-9]+)/Profile$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Profile&act=data&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="?following">
<match url="^/?@([0-9]+)/following$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Profile&act=following&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="?follower">
<match url="^/?@([0-9]+)/follower$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Profile&act=follower&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="?welcome">
<match url="^/?welcome$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Passport&act=login&%{QUERY_STRING}" />
</rule>
<rule name="?register">
<match url="^/?register$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=index&%{QUERY_STRING}" />
</rule>
<rule name="?activate">
<match url="^/?activate/([0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=waitForActivation&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="?review">
<match url="^/?review/([0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=waitForAudit&uid=$1&%{QUERY_STRING}" />
</rule>
<rule name="upload_photo">
<match url="^/?register/upload_photo$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=step2&%{QUERY_STRING}" />
</rule>
<rule name="work_information">
<match url="^/?register/work_information$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=step3&%{QUERY_STRING}" />
</rule>
<rule name="follow_interesting">
<match url="^/?register/follow_interesting$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Register&act=step4&%{QUERY_STRING}" />
</rule>
<rule name="?allfeed">
<match url="^/?allfeed$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Index&act=index&type=all&%{QUERY_STRING}" />
</rule>
<rule name="my_weibo">
<match url="^/?my/weibo$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Index&act=myFeed&%{QUERY_STRING}" />
</rule>
<rule name="my_following">
<match url="^/?my/following$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Index&act=following&%{QUERY_STRING}" />
</rule>
<rule name="my_follower">
<match url="^/?my/follower$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Index&act=follower&%{QUERY_STRING}" />
</rule>
<rule name="my_favorite">
<match url="^/?my/favorite$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Collection&act=index&%{QUERY_STRING}" />
</rule>
<rule name="atme">
<match url="^/?atme$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Mention&act=index&%{QUERY_STRING}" />
</rule>
<rule name="?comment_receive">
<match url="^/?comment/receive$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Comment&act=index&type=receive&%{QUERY_STRING}" />
</rule>
<rule name="comment_send">
<match url="^/?comment/send$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Comment&act=index&type=send&%{QUERY_STRING}" />
</rule>
<rule name="?message">
<match url="^/?message$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Message&act=index&%{QUERY_STRING}" />
</rule>
<rule name="?notify">
<match url="^/?notify$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Message&act=notify&%{QUERY_STRING}" />
</rule>
<rule name="message">
<match url="^/?message/([0-9]+)/([0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Message&act=detail&type=$1&id=$2&%{QUERY_STRING}" />
</rule>
<rule name="weibo">
<match url="^/?@([0-9]+)/weibo/([0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Profile&act=feed&uid=$1&feed_id=$2&%{QUERY_STRING}" />
</rule>
<rule name="?setting">
<match url="^/?setting$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=index&%{QUERY_STRING}" />
</rule>
<rule name="setting_domain">
<match url="^/?setting/domain$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=domain&%{QUERY_STRING}" />
</rule>
<rule name="setting_verify">
<match url="^/?setting/verify$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=authenticate&%{QUERY_STRING}" />
</rule>
<rule name="setting_privacy">
<match url="^/?setting/privacy$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=privacy&%{QUERY_STRING}" />
</rule>
<rule name="setting_notify">
<match url="^/?setting/notify$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=notify&%{QUERY_STRING}" />
</rule>
<rule name="setting_blacklist">
<match url="^/?setting/blacklist$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=blacklist&%{QUERY_STRING}" />
</rule>
<rule name="setting_security">
<match url="^/?setting/security$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=security&%{QUERY_STRING}" />
</rule>
<rule name="setting_bind">
<match url="^/?setting/bind$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Account&act=bind&%{QUERY_STRING}" />
</rule>
<rule name="?weiba">
<match url="^/?weiba$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=index&%{QUERY_STRING}" />
</rule>
<rule name="weiba_weibalist">
<match url="^/?weiba/weibalist$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=weibaList&%{QUERY_STRING}" />
</rule>
<rule name="weiba_postlist">
<match url="^/?weiba/postlist$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=postList&%{QUERY_STRING}" />
</rule>
<rule name="weiba_">
<match url="^/?weiba/([0-9]+)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=detail&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_digest">
<match url="^/?weiba/([0-9]+)/digest$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=detail&weiba_id=$1&type=digest&%{QUERY_STRING}" />
</rule>
<rule name="weiba_post">
<match url="^/?weiba/([0-9]+)/post$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=post&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_edit">
<match url="^/?weiba/([0-9]+)/edit$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=postEdit&post_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_detail">
<match url="^/?weiba/([0-9]+)/detail$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=postDetail&post_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_editreply">
<match url="^/?weiba/([0-9]+)/editreply$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Index&act=replyEdit&reply_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_manage">
<match url="^/?weiba/([0-9]+)/manage$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Manage&act=index&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_manage_member">
<match url="^/?weiba/([0-9]+)/manage/member$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Manage&act=member&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_manage_notify">
<match url="^/?weiba/([0-9]+)/manage/notify$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Manage&act=notify&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="weiba_manage_log">
<match url="^/?weiba/([0-9]+)/manage/log$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=weiba&mod=Manage&act=log&weiba_id=$1&%{QUERY_STRING}" />
</rule>
<rule name="?topics">
<match url="^/?topics/(.*)$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false" />
<action type="Rewrite" url="index.php?app=public&mod=Topic&act=index&domain=$1&%{QUERY_STRING}" />
</rule>
</rules>
</rewrite>
<defaultDocument lockAttributes="enabled">
<files>
<clear />
<add value="index.html" />
<add value="index.htm" />
<add value="index.php" />
<add value="Default.htm" />
<add value="Default.asp" />
<add value="iisstart.htm" />
</files>
</defaultDocument>
</system.webServer>
</configuration>

发表评论 取消回复