.htaccess: Redirect .pdf files with spaces in filename to pages

1
2
RewriteCond %{REQUEST_URI} ^/AAA-TARGETED-QUESTIONS-EXAMPLE.pdf$
RewriteRule ^(.*) /examples.html [L,R=301]
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Redirect .pdf files in your .htaccess file that have spaces in the filename. Also shows example of how to escape brackets in the filename.

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.