I have a folder on my site that contains bunch of pdf files. Is there a way to redirect any one trying to access these files to my new site?
for example if a user tries to access http://www.example.com/pdf/file.pdf
he gets redirected http://example2.com
.
I’ve managed to redirect normal posts using a wordpress 301 redirect plugin, however this is not working with pdf files.
I tried some htaccess rewrite i found on google but it broke the site.
Thanks.
Is there a way to redirect
Place this rule at top of your .htaccess (just below
RewriteEngine
line):