Forum Moderators: phranque
Your advice/view on this would be much appreciated.
In fact, this application does not require mod_rewrite, unless you want to use an internal rewrite rather than an external redirect. You can use the mod_alias RedirecMatch directive [httpd.apache.org] for a simple redirect.
In fact, it might be simpler to just rename your movie files to lowercase; If you do that, then no mod_rewrite or mod_alias directives will be needed at all.
But here's an example of mod_alias code:
RedirectMatch 301 ^/path_to_movie_dir/ref([0-9]+)_v([0-9]+)\.htm$ http://www.example.com/path_to_movie_dir/Ref$1_v$2.htm
Jim
I used RedirectMatch (mod_alias) and it's now working perfectly.
I had considered renaming my movie files to lowercase. However, they are packaged up with a locally-installed software product, as well as being available online. Consequently, to change all the references online and in the local software product would cause more problems than it's worth.
The mod_alias technique works beautifully so many thanks for that and particularly for the very apt example.