Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
After update to new version of Boost 1.18 I got this error:
"Your robots.txt file does not contain "Disallow: /boost_stats.php". This is needed in order to prevent the output of this from accidentally getting indexed by search engines."
But I have the line Disallow: /boost_stats.php in my robots.txt (chmod 644).
What to do?
Comment | File | Size | Author |
---|---|---|---|
#8 | boost-707272.patch | 2.68 KB | mikeytown2 |
robots.txt | 2.13 KB | superfedya |
Comments
Comment #1
mikeytown2 CreditAttribution: mikeytown2 commentedrobots.txt is only valid at the root level; I now check there.
example.com/robots.txt - Valid, change this one
example.com/drupal/robots.txt - Will not be read by a bot.
http://sitemaps.blogspot.com/2006/02/using-robotstxt-file.html
Now that I think about it, I should use the meta tag if possible.
http://www.mymommybiz.com/seo/metatagrobots.html
Will be hard to pull off. It might not be doable, since it embeds the html...
Comment #2
superfedya CreditAttribution: superfedya commentedOk, thanks, but I need write: Disallow: /boost_stats.php or Disallow: /mydrupalfolder/boost_stats.php?
Comment #3
mikeytown2 CreditAttribution: mikeytown2 commentedgood point.
Disallow: /mydrupalfolder/boost_stats.php
is what you wantComment #4
superfedya CreditAttribution: superfedya commentedThanks! Fixed.
Comment #5
mikeytown2 CreditAttribution: mikeytown2 commentedI need to put this fix in code
Comment #6
superfedya CreditAttribution: superfedya commentedSo, I changed this line Disallow: /boost_stats.php to Disallow: /mysite/boost_stats.php and got same error. Are You sure that its need be Disallow: /mysite/boost_stats.php and not just Disallow: /boost_stats.php?
Comment #7
mikeytown2 CreditAttribution: mikeytown2 commentedDisallow: /mysite/boost_stats.php is correct; I need to put it in code so it will check the correct thing. To make it shut-up for now, do both.
Comment #8
mikeytown2 CreditAttribution: mikeytown2 commentedthis should give correct info and check for the correct path if in a subdir
Comment #9
superfedya CreditAttribution: superfedya commentedfixed.
Comment #10
mikeytown2 CreditAttribution: mikeytown2 commentedComment #11
mikeytown2 CreditAttribution: mikeytown2 commentedcommitted
Comment #12
mikeytown2 CreditAttribution: mikeytown2 commentedComment #14
yngens CreditAttribution: yngens commentedThe issue is actual for 6.x-1.20.
Path in # is giving:
patching file boost.install
Reversed (or previously applied) patch detected! Assume -R? [n] y
Hunk #1 succeeded at 72 (offset 8 lines).
Hunk #2 FAILED at 182.
Hunk #3 succeeded at 242 (offset 9 lines).
1 out of 3 hunks FAILED -- saving rejects to file boost.install.rej
Comment #15
bgm CreditAttribution: bgm commented@ yngens: the patch has been committed and it shipped with 6.x-1.20. There is no need to apply the patch.
Besides, the patch is mainly to clarify how to modify your robots.txt. You still need to modify it manually.
Comment #16
yngens CreditAttribution: yngens commentedbgm, thanks for the comments, but before starting troubleshooting this and applying any patch I, of course, made sure to use the last version of the module. Could you please test this on a clean Drupal 6 install on CentOS machine to see the error message on status page is still there. My directory structure is as follows:
/home/username/public_html <---- and Drupal sits here, that is robots.txt is here: /home/username/public_html/robots.txt
and my robots.txt contains 'Disallow: /boost_stats.php'. To get rid of the message I tried all imaginable modifications of the path - the error marks doesn't want to go away. Is it only me or could anyone confirm with fresh Drupal install and the last version of the module?
Comment #17
bgm CreditAttribution: bgm commentedCan you copy-paste the complete error message?
Comment #18
bgm CreditAttribution: bgm commentedRe-closing, no activity. Please open a new bug report if the problem persists and you have a complete error message.