I’m tring to do a simple htaccess rewrite for a directory of SWF files.
The requested URLs look like this:
http://mysite.com/swf/gallery/galleryid
http://mysite.com/swf/movie/movieid
And I would like those rewritten to:
http://mysite.com/swf/gallery.swf?id=galleryid
http://mysite.com/swf/movie.swf?id=movieid
I thought the rule would be simple, but for some reason it is not rewriting properly. It cuts off everything after the .swf (output: http://mysite.com/swf/movie.swf), so I’m assuming there is something wrong with the question mark in my rule, but escaping it didn’t help. Here’s my rule, could someone help with this?
code:
RewriteRule ^swf/(.)/(.)$ swf/$1.swf?id=$2 [L]