Need help convert IIS URL rewrite rules to ISAPI Rewrite 2.1

ISAPI_Rewrite is a powerful URL manipulation engine based on regular expressions
User avatar
Posts: 3
Joined: 25 Mar 2014, 02:24

Need help convert IIS URL rewrite rules to ISAPI Rewrite 2.1

25 Mar 2014, 02:32

Hello,

My hosting server does not have IIS rewrite v2 installed. It does have the httpd.ini version 2.1.

Is there a converter that I can use to convert the rules?

Thanks,

Frank

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Need help convert IIS URL rewrite rules to ISAPI Rewrite

25 Mar 2014, 11:25

Hello,

Unfortunately there is none. Why are you trying to migrate to an old ISAPI_Rewrite, after some time you'd still end up upgrading to ISAPI_Rewrite3 or HeliconApe and you'll face the same problem.
If you have IIS6 or IIS7+ consider using ISAPI_Rewrite3 or HeliconApe and then Entrada could do some Premium Support to rewrite your rules.

Regards

User avatar
Posts: 3
Joined: 25 Mar 2014, 02:24

Re: Need help convert IIS URL rewrite rules to ISAPI Rewrite

01 Apr 2014, 09:12

Hi,

Thanks for reply! My hosting server does not have IIS rewrite version 2 installed. They have ISAPI Rewrite 2.1 installed.

Here is what I got from help desk.

My apologies for any inconvenience this issue might have caused you. Please note that we do not support URL rewrite v2 on any of the servers. However, if you are using ISAPI Rewrite – the httpd.ini then we support version 2.1 in all the servers.

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Need help convert IIS URL rewrite rules to ISAPI Rewrite

01 Apr 2014, 13:00

Ok. So do you want to convert something? If so, what type of rules to what type of rules?

Regards

User avatar
Posts: 3
Joined: 25 Mar 2014, 02:24

Re: Need help convert IIS URL rewrite rules to ISAPI Rewrite

02 Apr 2014, 04:59

Here are my IIS rewrite rules. I would really appreciate someone can help me convert them to ISAPI Rewrite 2.1 rules. I have no idea how to do it. Thanks a lot!


<rewrite>
<outboundRules>
<rule name="OutboundRewriteUserFriendlyURL1" preCondition="ResponseIsHtml1">
<match filterByTags="A, Form, Img" pattern="^(.*/)ShowListingDetail\.aspx\?ListingID=([^=&amp;]+)&amp;(?:amp;)?name=([^=&amp;]+)$" />
<action type="Rewrite" value="{R:1}{R:2}/{R:3}/" />
</rule>
<rule name="OutboundRewriteUserFriendlyURL2" preCondition="ResponseIsHtml1">
<match filterByTags="A, Form, Img" pattern="^(.*/)CategoryProducts\.aspx\?id=([^=&amp;]+)&amp;(?:amp;)?page=([^=&amp;]+)&amp;(?:amp;)?category=([^=&amp;]+)$" />
<action type="Rewrite" value="{R:1}CategoryProducts/{R:2}/{R:3}/{R:4}/" />
</rule>
<rule name="OutboundRewriteUserFriendlyURL3" preCondition="ResponseIsHtml1">
<match filterByTags="A, Form, Img" pattern="^(.*/)ProductListByBrand\.aspx\?id=([^=&amp;]+)&amp;(?:amp;)?page=([^=&amp;]+)&amp;(?:amp;)?brand=([^=&amp;]+)$" />
<action type="Rewrite" value="{R:1}ProductListByBrand/{R:2}/{R:3}/{R:4}/" />
</rule>
<preConditions>
<preCondition name="ResponseIsHtml1">
<add input="{RESPONSE_CONTENT_TYPE}" pattern="^text/html" />
</preCondition>
</preConditions>
</outboundRules>
<rules>
<clear />
<rule name="CanonicalHostNameRule1">
<match url="(.*)" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{HTTP_HOST}" pattern="^www\.manualbooksonline\.com$" negate="true" />
<add input="{URL}" pattern="\.axd$" negate="true" />
</conditions>
<action type="Redirect" url="http://www.manualbooksonline.com/{R:1}" />
</rule>
<rule name="LowerCaseRule1" stopProcessing="true">
<match url="[A-Z]" ignoreCase="false" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{URL}" pattern="\.axd$" negate="true" />
</conditions>
<action type="Redirect" url="{ToLower:{URL}}" />
</rule>
<rule name="AddTrailingSlashRule1" stopProcessing="true">
<match url="(.*[^/])$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{URL}" pattern="\.axd$" negate="true" />
</conditions>
<action type="Redirect" url="{R:1}/" />
</rule>
<rule name="RedirectUserFriendlyURL1" stopProcessing="true">
<match url="^ShowListingDetail\.aspx$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_METHOD}" pattern="^POST$" negate="true" />
<add input="{QUERY_STRING}" pattern="^ListingID=([^=&amp;]+)&amp;name=([^=&amp;]+)$" />
</conditions>
<action type="Redirect" url="{C:1}/{C:2}" appendQueryString="false" />
</rule>
<rule name="RewriteUserFriendlyURL1" stopProcessing="true">
<match url="^([^/]+)/([^/]+)/?$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="ShowListingDetail.aspx?ListingID={R:1}&amp;name={R:2}" />
</rule>
<rule name="RedirectUserFriendlyURL2" stopProcessing="true">
<match url="^CategoryProducts\.aspx$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_METHOD}" pattern="^POST$" negate="true" />
<add input="{QUERY_STRING}" pattern="^id=([^=&amp;]+)&amp;page=([^=&amp;]+)&amp;category=([^=&amp;]+)$" />
</conditions>
<action type="Redirect" url="CategoryProducts/{C:1}/{C:2}/{C:3}" appendQueryString="false" />
</rule>
<rule name="RewriteUserFriendlyURL2" stopProcessing="true">
<match url="^CategoryProducts/([^/]+)/([^/]+)/([^/]+)/?$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="CategoryProducts.aspx?id={R:1}&amp;page={R:2}&amp;category={R:3}" />
</rule>
<rule name="RedirectUserFriendlyURL3" stopProcessing="true">
<match url="^ProductListByBrand\.aspx$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_METHOD}" pattern="^POST$" negate="true" />
<add input="{QUERY_STRING}" pattern="^id=([^=&amp;]+)&amp;page=([^=&amp;]+)&amp;brand=([^=&amp;]+)$" />
</conditions>
<action type="Redirect" url="ProductListByBrand/{C:1}/{C:2}/{C:3}" appendQueryString="false" />
</rule>
<rule name="RewriteUserFriendlyURL3" stopProcessing="true">
<match url="^ProductListByBrand/([^/]+)/([^/]+)/([^/]+)/?$" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Rewrite" url="ProductListByBrand.aspx?id={R:1}&amp;page={R:2}&amp;brand={R:3}" />
</rule>

</rules>
</rewrite>

User avatar
Posts: 1264
Joined: 07 Mar 2012, 10:16

Re: Need help convert IIS URL rewrite rules to ISAPI Rewrite

02 Apr 2014, 09:30

hm... I'm not a pro about this either...

You can try to describe what these do and we'll try to help you out.
OR
You can ask HeliconTech for assistance using their Premium Support Plan. They are notorious in this.

Regards

Return to ISAPI_Rewrite 2.x

Who is online

Users browsing this forum: No registered users and 14 guests