I have the following Apache Rewrite rule
<IfModule rewrite_module>
RewriteEngine on
RewriteMap tolowercase int:tolower
RewriteCond $2 [A-Z]
RewriteRule ^(.*)/(.*).html$ $1/${tolowercase:$2}.html [R=301,L]
</IfModule>
that changes this:
http://localhost.localdomain.com/FooBarBaz.html
to this:
http://localhost.localdomain.com/foobarbaz.html
I'd like to port it to this tuckey.org URL Rewrite Filter.
What is an equivalent rule that I could use to make the URL lowercase? I'm particularly interested in how to form the condition element.
Here's my first cut at the rule, but it doesn't work, even without the condition:
<rule>
<name>Force URL filenames to lower case</name>
<from>^(.*)/(.*).html$</from>
<to type="permanent-redirect" last="true">$1/${lower:$2}.html</to>
</rule>