This forum has been moved here:
Helicon Tech Community Forum

ISAPI_Rewrite 3.0 (Forum Locked Forum Locked)
 Helicon Tech : ISAPI_Rewrite 3.0
Subject Topic: URL rewrite with paging.
Author
Message |
mmc501
Newbie


Joined: 05 February 2010
Posts: 25
Posted: 24 October 2011 at 10:56pm

I have a simple page rewrite whuich is not working and I don't know why.

Url

/blog/2011/2

to go to

/blog/?yr=2011&p=2

My url rewrite is:
RewriteRule blog/([^/?]+)/([^/?]+) /blog/?yr=$1&p=$2 [I,U]


My Rewrite.log is:

127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (2) init rewrite engine with requested uri /blog/2011/2
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (1) Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (1) Htaccess process request c:\users\martin\documents\my websites\domainname\blog\.htaccess
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (3) applying pattern '^([^.?]+[^.?/])$' to uri 'blog/2011/2'
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (1) escaping /blog/2011/2/
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (2) explicitly forcing redirect with http://local.domainname.com/blog/2011/2/
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (2) internal redirect with /blog/2011/2 [INTERNAL REDIRECT]

127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (2) init rewrite engine with requested uri /blog/2011/2/
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (1) Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (1) Htaccess process request c:\users\martin\documents\my websites\domainname\blog\.htaccess
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (3) applying pattern '^([^.?]+[^.?/])$' to uri 'blog/2011/2/'
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (3) applying pattern '.?' to uri 'blog/2011/2/'
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (4) RewriteCond: input='local.domainname.com' pattern='(.*)' => matched
127.0.0.1 127.0.0.1 Tue, 25-Oct-2011 04:50:55 GMT [local.domainname.com/sid#51][rid#23980824/initial] (4) RewriteCond: input='off' pattern='on' => not-matched

What have I done wrong?



Edited by mmc501 - 24 October 2011 at 10:57pm
Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 26 October 2011 at 4:22am

Hello,

You have other rules in your config file that come up and process request first.
You may try to put this rule on top of the others.

Regards
Andrew
Back to Top
 
mmc501
Newbie


Joined: 05 February 2010
Posts: 25
Posted: 26 October 2011 at 7:02pm

Thanks, noticed the .htaccess file in the blog folder which was causing the problems.

Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version