html2pdf
html2pdf copied to clipboard
prevent the crawl of the google robot
Hi,
how to prevent the google robot from indexing PHP pages that generate PDF? I added the code below in my htaccess file but it doesn't prevent google from crawling the page because it's in PHP.
#Block indexing of Word and PDF files <files ~ ".(doc|docx|pdf)$"> Header Set X-Robots-Tag "noindex, nofollow </Files>
Hello,
this is not linked with html2pdf, but with apache configuration
Regards,
You can try adding X-Robots-Tag HTTP Response header in the script that generates your PDF file. Source