[thelist] replace chars in url with mod_rewrite

Richard Livsey Richard at livsey.org
Mon Jul 19 11:58:35 CDT 2004

Is it possible to mod_rewrite a URL to replace certain characters?

We host a site who use spaces in their filenames extensively. A third 
pary application they use creates links with the spaces replaced with 
'+' so links from this app break.
Unfortunately they can't change the app, or the filenames so we are 
forced to look at alternatives.

So the challenge is how to convert a URL like:

I've searched the mod_rewite docs but couldn't find anything of use.

Another resort is to make a custom 404 handler which will redirect to 
the correct URL, but mod_rewrite feels cleaner.

Thanks in advance.

Incutio Web Developer

More information about the thelist mailing list