mod_rewrite issue
I have some old files that need to point to new files - the old files are indexed from Google like this: old%20file%20here.pdf
- because the last people doing the site left spaces in file names - but in my Rewrites they just aren't matching the old file to send to the new - does anyone know how to ignore the %20
and redirect right?
My rewrite code here:
RewriteRule ^downloads/old%file%20here.pdf$ http://www.domain.co.uk/new-file.pdf [R=301,L]
Its working 开发者_如何学Cfine for rest of redirects which are pages with normal URLs.
found the answer, this is it
[space]name (so should be \ name) instead of what i was doing which was \%20name
hope this helps any one else!
精彩评论