Weather Related Organizations > WeatherUnderground
wxwuhistory.php Persistent Server Errors
gwwilk:
This script, wxwuhistory.php via its includes script, WU-History-inc.php, regularly generates server errors. This amounted to over 70 MB in just the last week.
Here's a sample of the errors (sanitized):
--- Code: ---[28-Aug-2020 12:53:04 America/Chicago] PHP Notice: A non well formed numeric value encountered in (my Server's home)/WU-History-inc.php on line 1399
[28-Aug-2020 12:53:04 America/Chicago] PHP Notice: Undefined variable: SERVER in (my Server's home)/WU-History-inc.php on line 397
[28-Aug-2020 12:53:04 America/Chicago] PHP Notice: A non well formed numeric value encountered in (my Server's home)/WU-History-inc.php on line 1399
[28-Aug-2020 12:54:17 America/Chicago] PHP Notice: Undefined variable: SERVER in (my Server's home)/WU-History-inc.php on line 397
--- End code ---
Any thoughts anyone? (And, yes, I know. I should just give up on the current shadow of its former self, WU!)
saratogaWX:
You might try the Version 3.4g - 27-Apr-2020 from here
BTW.. the error on 397 was for $SERVER['PHP_SELF'] which should be $_SERVER['PHP_SELF']
gwwilk:
Thanks very much, Ken!
The latest version works, after suitable customization, and my error log is no longer being populated by running the script.
Much appreciated! [tup]
dasman:
I have updated my script to 3.4h. I verified all of my settings were customized. I have loaded the new script and my page does not show the data? https://www.peotoneweather.com/wxwuhistory.php. If I click on the Comma Delimited File I can see that. It is the Display table that is blank. Any Ideas?
saratogaWX:
--- Quote from: dasman on September 11, 2022, 12:13:08 PM ---I have updated my script to 3.4h. I verified all of my settings were customized. I have loaded the new script and my page does not show the data? https://www.peotoneweather.com/wxwuhistory.php. If I click on the Comma Delimited File I can see that. It is the Display table that is blank. Any Ideas?
--- End quote ---
I think the issue is in WU-history-inc.php .. a function is returning http as access for the WXDailyHistory.php host for your site, and your site is doing an automatic redirect from http to https.
Try changing
--- Code: --- $url = (false and (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') || $port == 443) ? "https://" : "http://";
--- End code ---
to
--- Code: --- $url = (false and (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] != 'off') || $port == 443) ? "https://" : "https://";
--- End code ---
to force it to use the https protocol.
Navigation
[0] Message Index
[#] Next page
Go to full version