Isapi Rewrite : Remove filename from URL
Posted
by namtax
on Stack Overflow
See other posts from Stack Overflow
or by namtax
Published on 2010-04-19T19:43:27Z
Indexed on
2010/06/08
10:22 UTC
Read the original article
Hit count: 681
mod-rewrite
|isapi-rewrite
Hi there
Im am trying to use the isapi rewrite tool on my web domain to write some basic rules, but am getting a bit confused.
My base url is http://forevr-dev.co.uk/musicexplained/index.cfm and every page on the site follows from this base url. For example http://forevr-dev.co.uk/musicexplained/index.cfm/artist/blondie would be the artist page for blondie..
What I am looking for, is a rewrite rule, that would remove the index.cfm from the url, instead leaving http://forevr-dev.co.uk/musicexplained/artist/blondie.
I have put the httpd.ini file in my musicexplained folder, under the root of my forevr-dev.co.uk domain, and I am using the following code below, which I used from the coldbox coldfusion framework application examples.
RewriteEngine On
RepeatLimit 0
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.cfm/%{REQUEST_URI} [QSA,L]
However, when I now go to the new pretty url, I am recieving an error message saying that the page cannot be found, alongside a 404 message.
Any ideas?
Thanks
© Stack Overflow or respective owner