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: Magento rewrite rules conversion
Author
Message |
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 22 February 2011 at 9:20am

Hi there,

I have looked at an old thread which is closed and I
can't reply on which covers the Magento rewrite rules
conversion; thread is here:
http://www.helicontech.com/forum/13029-
Magento_Conversion.html

I have used those rules in my ISAPI 3 and they work
nicely :) The only issue I have is that my URL's are
coming out...

like this:
http://www.masksfromvenice.com/index.php/masquerade-
masks.html

instead of this:
http://www.masksfromvenice.com/masquerade-masks.html

any bright ideas? Here's my rules:

Code:
# Helicon ISAPI_Rewrite configuration file
# Version 3.1.0.76

RewriteEngine on
RewriteBase /
RewriteRule .* -
[E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteCond %{REQUEST_URI} !^/(media|skin|js)/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule .* index.php [L]


Thank you,
Matt
Back to Top Visit Matt Morrison's Homepage
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 24 February 2011 at 5:44pm

HEllo Matt,

First suggestion - please, all [L] flag to all of the rules.
Second: please, provide the rewrite.log for the testing request.
Logging issues described in FAQ

Regards
Andrew
Back to Top
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 27 February 2011 at 12:18pm

Hi,

Thanks that worked a treat

Regards,
Matt.
Back to Top Visit Matt Morrison's Homepage
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 28 February 2011 at 2:05am

Hi,

Everything worked ok yesterday but I've woken up after a
product import procedure to find that ever URL is now
leading to a 404 page; if you manually type in the
index.php part it finds it again.

not working 404: http://www.masksfromvenice.com/italian-
masks.html
working typed manually:
http://www.masksfromvenice.com/index.php/italian-
masks.html

there is no error.log after enabling and this is my
rewrite.log file contents:


(2) init rewrite engine with requested uri /italian-masks.html
(1) Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
(1) Htaccess process request c:\opal logicdata\accounts\masks from venice\masksfromvenice.com\wwwroot\.htaccess
(3) applying pattern '.*' to uri 'italian-masks.html'
(1) Rewrite URL to >> /italian-masks.html
(2) rewrite 'italian-masks.html' -> '/italian-masks.html'
(2) internal redirect with /italian-masks.html [INTERNAL REDIRECT]

(2) init rewrite engine with requested uri /favicon.ico
(1) Htaccess process request C:\Program Files\Helicon\ISAPI_Rewrite3\httpd.conf
[www.masksfromvenice.com/sid#14][rid#99655192/initial]
(1) Htaccess process request c:\opal logic data\accounts\masks fromvenice\masksfromvenice.com\wwwroot\.htaccess
(3) applying pattern '.*' to uri 'favicon.ico'
(1) Rewrite URL to >> /favicon.ico
(2) rewrite 'favicon.ico' -> '/favicon.ico'
(2) internal redirect with /favicon.ico [INTERNAL REDIRECT]

Please help, thanks Matt.

Edited by AndrushkaUS - 28 February 2011 at 4:25am


__________________
Cheers, Matt Morrison
Opal Logic Ltd
Back to Top Visit Matt Morrison's Homepage
 
Guests
Guest


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

Hello Matt,

I modified you logs to make them more obvious.
I don't see any conditions being applied. As if the config file is different.

Regards
Andrew
Back to Top
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 28 February 2011 at 4:30am

Hi Andrew,

when you say config file, do you mean the .htaccess file or
the httpd.conf under ISAPI install dir?

I have looked at the .htaccess and it's exactly the same as
before.

Cheers,
Matt.
Back to Top Visit Matt Morrison's Homepage
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 28 February 2011 at 9:55am

I have now had this in the error.log

[28/02/2011 15:54:42] Unknown expression in the file
c:\opal logic data\accounts\masks from
venice\masksfromvenice.com\wwwroot\media\.htaccess, on
the line #1: Options All -Indexes
[28/02/2011 15:54:42] Unknown expression in the file
c:\opal logic data\accounts\masks from
venice\masksfromvenice.com\wwwroot\media\.htaccess, on
the line #6: AddHandler cgi-script .php .pl .py .jsp .asp
.htm .shtml .sh .cgi
[28/02/2011 15:54:42] Unknown expression in the file
c:\opal logic data\accounts\masks from
venice\masksfromvenice.com\wwwroot\media\.htaccess, on
the line #7: Options -ExecCGI
[28/02/2011 15:54:42] c:\opal logic data\accounts\masks
from venice\masksfromvenice.com\wwwroot\media\.htaccess -
Loaded successfully
Back to Top Visit Matt Morrison's Homepage
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 28 February 2011 at 10:00am

aah, I can see that refers to a apache .htaccess file
under a media folder which I've now renamed so its not
picked up.

But I still have the same issue with rewrites as above.
Any suggestions?

not working 404: http://www.masksfromvenice.com/italian-
masks.html
working typed manually:
http://www.masksfromvenice.com/index.php/italian-
masks.html

Here is the .htaccess under the root of the site:

# Helicon ISAPI_Rewrite configuration file
# Version 3.1.0.76

RewriteLogLevel 9
LogLevel debug

RewriteEngine on
RewriteBase /
RewriteRule .* -
[L,E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteCond %{REQUEST_URI} !^/(media|skin|js)/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule .* index.php [L]

Thanks, Matt.
Back to Top Visit Matt Morrison's Homepage
 
Guests
Guest


Joined: 01 October 2003
Online Status: Online
Posts: -160
Posted: 01 March 2011 at 4:52am

Matt, rules are just okay. The only thing to look up to is log. We need it to understand what happens with request.
Please, provide log after all modifications you've made.

Regards
Andrew
Back to Top
 
Matt Morrison
Groupie


Joined: 01 October 2007
Location: United Kingdom
Posts: 52
Posted: 17 February 2012 at 10:36am

Hi, I had to migrate my website and I'm having issues
again.

The rules are installed the same, isapi is enabled in
iis7 but I keep getting 404's.

This will work:
http://www.masksfromvenice.com/index.php/masquerade-masks

This won't: http://www.masksfromvenice.com/masquerade-
masks

I have enabled debugging and the error.log shows this:

[17/02/2012 16:27:45] c:\opal logic data\accounts\opal
logic\masksfromvenice.com\wwwroot\.htaccess - Loaded
successfully
[17/02/2012 16:28:42] C:\Program
Files\Helicon\ISAPI_Rewrite3\httpd.conf - Loaded
successfully
[17/02/2012 16:28:42] Credentials [Opal Logic Ltd, #####-
#####-#####-#####] are valid.
[17/02/2012 16:28:42] ISAPI Filter loaded. Version
3.1.0.76. Windows 6.1 (Build 7600 ServicePack:0)
ProductType SERVER. CPU type AMD64 NumberOfProcessors 8.
[17/02/2012 16:28:42] c:\opal logic data\accounts\opal
logic\masksfromvenice.com\wwwroot\.htaccess - Loaded
successfully

I just found the rewrite.log file...it seems to be
writing to itself?

(2) init rewrite engine with requested uri /masquerade-
masks
(1) Htaccess process request C:\Program
Files\Helicon\ISAPI_Rewrite3\httpd.conf
(1) Htaccess process request c:\opal logic
data\accounts\opal
logic\masksfromvenice.com\wwwroot\.htaccess
(3) applying pattern '.*' to uri 'masquerade-masks'
(1) Rewrite URL to >> /masquerade-masks
(2) rewrite 'masquerade-masks' -> '/masquerade-masks'
(2) internal redirect with /masquerade-masks [INTERNAL
REDIRECT]

Edited by Matt Morrison - 17 February 2012 at 10:49am


__________________
Cheers, Matt Morrison
Opal Logic Ltd
Back to Top Visit Matt Morrison's Homepage
 
Guests
Guest


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

Seems like it simply added slash in front.
Please, provide the content of .htaccess as it is.

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