On Mon, Jun 14, 2010 at 3:54 PM, Ben Timby <[email protected]> wrote:
>> http://mysite.com/login    <-- works.
>>
>> How do I make it so "login" can be case in-sensitive?  Login, LOGIN,
>> LoGiN ?

> 1. Map / to your WSGI app, and then login/Login/LOGIN will all be handled by 
> it.
> 2. Make apache case-insensitive? Perhaps:

Or 3. Use multiple mappings for the expected common variants.

WSGIScriptAlias /login /var/wsgi/login.wsgi
WSGIScriptAlias /Login /var/wsgi/login.wsgi
WSGIScriptAlias /LOGIN /var/wsgi/login.wsgi

because, really, do you expect to see "LoGiN"?


However, you should consider whether you really do want case
insensitivity anyway.  Some may argue that web resources should
have a single well-known canonical name.   After all, URLs
and URIs are generally case-sensitive anyway (except for the
hostname portion, which because of historic DNS conventions
are case-insensitive).

Also by having multiple case-variants for your URLs you may
be defeating web caching, spiders (for search engines),
and so forth.


If you want to allow for case insensitivity yet still have a single
canonical URL, you should really use redirects,

Redirect permanent /Login /login
Redirect permanent /LOGIN /login

-- 
Deron Meranda
http://deron.meranda.us/

-- 
You received this message because you are subscribed to the Google Groups 
"modwsgi" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/modwsgi?hl=en.

Reply via email to