简体   繁体   中英

IIS7 URL rewrite error

This is my url: http://www.domain.com/advertenties/advertentie-delen/?id=23&t=1&url=ad-placed-for-simons-company-by-me

With the rewrite rule below I get this error: "The page cannot be displayed because an internal server error has occurred"

<rule name="share ad">
<match url="^advertenties/advertentie-delen?/?$" />
<action type="Rewrite" url="share_email.aspx?id={R:1}" appendQueryString="true" />
</rule>

Found it. It says this "id={R:1}",which means it expects a variable on the match url tag. Since there was no variable it throws an error, this is what I have now:

    <rule name="share ad">
<match url="^advertenties/advertentie-delen?/?$" />
<action type="Rewrite" url="share_email.aspx" appendQueryString="true" />
</rule>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM