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.
Notice: Undefined index: HTTP_REFERER in statistics_exit() (line 83 of /DRUPAL7/modules/statistics/statistics.module).
I'm thinking that maybe FF6 isn't supplying referrer data. Just a guess, but my logs are getting filled up with this silly php notice.
Any reason not to do:
'url' => (issset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '',
Comment | File | Size | Author |
---|---|---|---|
#1 | 1253298-statistics_exit_http_referer-1.patch | 584 bytes | bfroehle |
Comments
Comment #1
bfroehle CreditAttribution: bfroehle commentedYes, we should use the isset($_SERVER['HTTP_REFERER']) ? ... pattern, just like in watchdog().
Comment #2
karschsp CreditAttribution: karschsp commentedPatch applies to both 7.x and 8.x. RTBC.
Comment #3
Dries CreditAttribution: Dries commentedCommitted to 7.x and 8.x. Thanks.
Comment #4
mgiffordExcellent. @bfroehle thanks for rolling up the patch. @Dries thanks & wish I was able to hang out in the code sprint after DrupalCon.