简体   繁体   中英

Drupal “page not found” error keeps getting logged in Recent Log Entries

Our website keeps logging a "page not found" error under the Drupal Recent Log Entries, but we do not know where it is coming from. When clicking into the detail of the error, the location is marked as "http:///*", user is "Guest", and severity is "warning". Does anybody have ideas on where we can find out what's causing these errors to log?

do you have atypo error in your code? check if you have mistakenly commented coz i see /* in the link. This has to be a local error. I would check for my drupal_goto calls in my code. this is my guess and i'm no drupal expert. let us know if it helps. atb!

Page not found warnings like this can be caused every kind of code that triggers an http request, like loading a .js or .css file or an image. A way to debug this is the quick-and-dirty method described by Lullabot which means that you add a debug_backtrace() at the point where the warning is registered (in your case probably the watchdog() function, see the comment by Randy Fay ).

PS. @Arvind: If you're using the Drupal API correctly, there shouldn't be too many drupal_goto calls in your code.

You might have an issue with your favicon like I did, although I don't recalling it generating errors in my watchdog. It's what triggered a lot of page not founds on my setup.

Basically, you normally put your favicon in your root. However, some browsers ( I believe IE6 ) , don't check the root for your favicon, but your theme folder. I just duplicated my favicon in my theme folder, and my problem was solved.

Worth a try.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM