[thelist] Rewrite using htaccess

Todd Richards todd at promisingsites.com
Tue Jun 21 16:04:38 CDT 2011

Hi Everyone -

I just moved a site from classic ASP to a PHP based system
(ExpressionEngine).  I've got most of my old pages set up with a 301
redirect and they are working fine.  However, I've got a few old ASP pages
that used a querystring.  

Ex: calendar.asp?m=04 (for April) or gallery.asp?category=20

For the first one, I want to just direct it to the calendar page which
displays all of the latest events.  So the new URL would be
http://www.site.com/index.php/calendar/.  However, the best I can get is
http://www.site.com/index.php/calendar/?04, which is invalid and then
redirects to the 404 page.

This has gotten me the closest so far:  
RewriteCond %{QUERY_STRING} m=
RewriteRule (.*) http://www.site.com/index.php/calendar/ [L,R=301]

I would be forever grateful for any adjustments that would get this working.



More information about the thelist mailing list