Forum Moderators: phranque

Message Too Old, No Replies

redirectmatch

redirectmatch

         

rasin

12:04 pm on Sep 1, 2005 (gmt 0)

10+ Year Member



hello all
i have this line in my htaccess file:
RedirectMatch 301 (.*)\.html$ http://www.example.com$1.shtml
it does the redirect and all
but there are 2 file i want to stay with the .html
how can i do this

Thanks

[edited by: trillianjedi at 12:44 pm (utc) on Sep. 1, 2005]
[edit reason] Examplified [/edit]

jdMorgan

3:57 pm on Sep 1, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



rasin,

You'll need to use mod_rewrite to do these redirects, and use mod_rewrite's RewriteCond directive to make the redirects conditional.

Our forum charter contains references for mod_rewrite and related subjects, and there are several good tutorials available in the Apache section of the WebmasterWorld library (See the charter and library links at the top of this page).

Jim