This forum has been moved here:
Helicon Tech Community Forum

Helicon Ape (Forum Locked Forum Locked)
 Helicon Tech : Helicon Ape
Subject Topic: Rewrite Rule doing a 301
Author
Message |
redapollos
Newbie


Joined: 07 May 2008
Posts: 5
Posted: 17 February 2012 at 1:07pm

I have the following URL that is doing a 301 when it should just be rewriting the URL:

http://dev.electronicdesign.com/product/components/hand-formable-coax-assemblies

Here's the rule

RewriteEngine On
RewriteBase /

RewriteRule ^/(article|product)/([^\/]*)/([^\/]*)$ /content?topic=$3&catpath=$2 [QSA,L,NC]

It's being 301 redirected to:

http://dev.electronicdesign.com/content/?topic=hand-formable-coax-assemblies&catpath=components

I've just installed Ape, I used to use Isapi Rewrite 3. What am I missing? 
Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 20 February 2012 at 4:00am

Hello,

The syntax for Ape is the same.
I'm not sure what's happening. But the rule you need should look like:

Code:
RewriteEngine On
RewriteBase /

RewriteRule ^(article|product)/([^\/]*)/([^\/]*)$ /content?topic=$3&catpath=$2 [NC,L]


If this won't work, please, provide rewrite.log for the testing request. The logging enabling is commented in httpd.conf. Just un-comment it.

Regards
Andrew
Back to Top
 
redapollos
Newbie


Joined: 07 May 2008
Posts: 5
Posted: 21 February 2012 at 6:08pm

Here's what's I'm seeing in the logging:


192.168.49.41 192.168.49.41  [21/Feb/2012:18:02:15] [dev.electronicdesign.com/sid#31][rid#13373949/initial] (1) [perdir e:\websites\dnn_ed3\] init rewrite engine with /article/power/Fundamentals-Of-Low-Power-Design--64714
192.168.49.41 192.168.49.41  [21/Feb/2012:18:02:15] [dev.electronicdesign.com/sid#31][rid#13373949/initial] (3) [perdir e:\websites\dnn_ed3\] applying pattern ^/(article|product)/([^\/]*)/([^\/]*)$ to uri /article/power/Fundamentals-Of-Low-Power-Design--64714
192.168.49.41 192.168.49.41  [21/Feb/2012:18:02:15] [dev.electronicdesign.com/sid#31][rid#13373949/initial] (1) [perdir e:\websites\dnn_ed3\] Rewrite URL to >> /content?topic=Fundamentals-Of-Low-Power-Design--64714&catpath=power [REWRITE]
192.168.49.41 192.168.49.41  [21/Feb/2012:18:02:15] [dev.electronicdesign.com/sid#31][rid#13373949/initial] (1) [perdir e:\websites\dnn_ed3\] Rewrite URL /article/power/Fundamentals-Of-Low-Power-Design--64714 to >> /content [INTERNAL_REDIRECT]

Also from the use of my browser tools, I'm definitely seeing a 301 redirect happening.  Help!

thanks.
Back to Top
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 22 February 2012 at 5:47am

Well, log shows only rewrite, not redirect.
Do you have any other rules? Do you have ISAPI_Rewrite installed at the same time?

Regards
Andrew
Back to Top
 

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

Printable version Printable version