Trouble with a URL rewrite

ISAPI_Rewrite is Apache mod_rewrite compatible URL rewriter for Microsoft IIS
User avatar
Posts: 4
Joined: 06 Jun 2012, 15:23

Trouble with a URL rewrite

06 Jun 2012, 15:26

Hello,
IM writting this rewrite
RewriteRule ^blog.html$ /blog [R=301,L]

it rewrites the name for the blog home page but if you click on a blog article it still resolves as http://www.website.com/blog.html/documentmanagement

I want it to remove the HTML even when selecting child pages.

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

Re: Trouble with a URL rewrite

07 Jun 2012, 05:01

Hello,

Please, try using the following:

Code: Select all
RewriteRule ^blog\.html(.*)$ /blog$1 [NC,R=301,L]


Regards
Andrew

User avatar
Posts: 4
Joined: 06 Jun 2012, 15:23

Re: Trouble with a URL rewrite

07 Jun 2012, 11:32

Thanks that worked.

User avatar
Posts: 4
Joined: 06 Jun 2012, 15:23

Re: Trouble with a URL rewrite

26 Jul 2012, 19:02

Hello, ONe more thing. I have one page that is adding an extra path. How do I remove it, so
http://www.website.com/blog.html/blog/page/2
It needs to be
http://www.website.com/blog/page/2

Need to remove the html and the extra blog path. How will this rewrite be different than the one previously mentioned.

thanks,

User avatar
Posts: 4
Joined: 06 Jun 2012, 15:23

Re: Trouble with a URL rewrite

08 Aug 2012, 19:17

Any help would be appreciated.

Return to ISAPI_Rewrite 3.0

Who is online

Users browsing this forum: No registered users and 5 guests