cloudy cloudy

Author Topic: wxquake.php not working  (Read 524 times)

0 Members and 1 Guest are viewing this topic.

Offline ptsdds

  • Posts: 75
  • Lodi, California
  • OS/Browser:
  • Win NT 10.0
  • Chrome 75.0.3770.100
    • Lodi Lake Wilderness Area
wxquake.php not working
« on: July 06, 2019, 04:47:20 PM »
I would very much appreciate some help.
My quakes page stopped updating 3-4 days ago and now the page is blank....  https://www.patricksweeneydds.com/wxquake.php .  I have not edited or changed anything and I have been using Ken's script v 2.0  for the last year. 
Furthermore,  https://www.patricksweeneydds.com/quakes.php  only shows the header. 

The last time I saw the working page was July 3,  just before the 6.4 quake in SoCal.  The last quake showing was a 5.0 and now nothing.
I live about 250 mi from the epicenter and did notice the swimming pool sloshing side to side and a swinging chandelier so it had to be a big one.

Frustrated

Offline wvdkuil

  • Wim van der Kuil
  • Posts: 1,291
  • Leuven Belgium CET
  • OS/Browser:
  • Mac OS X 10.13.6
  • Chrome 75.0.3770.100
    • My PWS at Leuven Belgium Europe
Re: wxquake.php not working
« Reply #1 on: July 06, 2019, 05:19:44 PM »
I would very much appreciate some help.
My quakes page stopped updating 3-4 days ago and now the page is blank....  https://www.patricksweeneydds.com/wxquake.php .  I have not edited or changed anything and I have been using Ken's script v 2.0  for the last year. 
Furthermore,  https://www.patricksweeneydds.com/quakes.php  only shows the header. 

The last time I saw the working page was July 3,  just before the 6.4 quake in SoCal.  The last quake showing was a 5.0 and now nothing.
I live about 250 mi from the epicenter and did notice the swimming pool sloshing side to side and a swinging chandelier so it had to be a big one.

Frustrated

The Saratoga scripts still work at the sites here, and at http://saratoga-weather.org/earthquake.php
It must be something in your setup, I think.

It is therefor also frustrating for people who want to help,  if the site only returns 
Quote
Forbidden
You don't have permission to access /wxquake.php on this server.

Wim,
from Belgium, country code  BE

Offline ptsdds

  • Posts: 75
  • Lodi, California
  • OS/Browser:
  • Win NT 10.0
  • Chrome 75.0.3770.100
    • Lodi Lake Wilderness Area
Re: wxquake.php not working
« Reply #2 on: July 06, 2019, 05:28:47 PM »
Strange.  Can you access other pages on my site or is that the only one that is Forbidden?   
I checked the permissions for wxquake.php and it is 0644

Offline niko

  • syzygy
  • Global Moderator
  • Posts: 28,126
  • Crystal Ball broken! Please post the URL.
  • Northern California, U.S.A.
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
Re: wxquake.php not working
« Reply #3 on: July 06, 2019, 05:31:54 PM »
The script is working on my server.

I don't get 404 error from either of the url's in your post.

Offline wvdkuil

  • Wim van der Kuil
  • Posts: 1,291
  • Leuven Belgium CET
  • OS/Browser:
  • Mac OS X 10.13.6
  • Chrome 75.0.3770.100
    • My PWS at Leuven Belgium Europe
Re: wxquake.php not working
« Reply #4 on: July 06, 2019, 05:56:33 PM »
Strange.  Can you access other pages on my site or is that the only one that is Forbidden?   
I checked the permissions for wxquake.php and it is 0644
With chrome, Safari and FF for these URL's I get a 403
https://www.patricksweeneydds.com/wxquake.php
https://www.patricksweeneydds.com/quakes.php
https://www.patricksweeneydds.com/
Code: [Select]
Request URL: https://www.patricksweeneydds.com/
Request Method: GET
Status Code: 403 Forbidden
Remote Address: 66.96.149.1:443
Referrer Policy: no-referrer-when-downgrade

Maybe you or your provider blocked access from abroad?
Wim

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • iOS 12.3.1
  • Safari 12.1.1
    • Saratoga Weather
Re: wxquake.php not working
« Reply #5 on: July 06, 2019, 07:25:59 PM »
The USGS server is quite loaded at this time so some requests for the Jason data fail.  The scripts are working..I canít help the USGS server loading issue.
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline ptsdds

  • Posts: 75
  • Lodi, California
  • OS/Browser:
  • Win NT 10.0
  • Chrome 75.0.3770.100
    • Lodi Lake Wilderness Area
Re: wxquake.php not working
« Reply #6 on: July 06, 2019, 07:34:07 PM »
OK.  For now I have put another menu item below "Earthquakes" named "Earthquakes link" , linking to the USGA site for California. 
Maybe things will sort out after awhile.

Offline niko

  • syzygy
  • Global Moderator
  • Posts: 28,126
  • Crystal Ball broken! Please post the URL.
  • Northern California, U.S.A.
  • OS/Browser:
  • Win 7/Srvr 2008R2
  • Chrome 75.0.3770.100
Re: wxquake.php not working
« Reply #7 on: July 06, 2019, 07:42:11 PM »
The USGS server is quite loaded at this time so some requests for the Jason data fail.  The scripts are working..I canít help the USGS server loading issue.

Confirmed, my page is down at the moment: "The USGS feed for earthquakes was not available at this time."

Offline Harry

  • Posts: 792
  • Union City, CA USA
  • OS/Browser:
  • Win NT 10.0
  • Firefox 67.0
    • Union City, CA Weather
Re: wxquake.php not working
« Reply #8 on: July 09, 2019, 09:21:39 PM »
I am getting not available or just the header now also.  I saw that Ken's page was working earlier but, now he is getting it too.

https://ucweather.org/wxquake.php

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • Win NT 10.0
  • Firefox 67.0
    • Saratoga Weather
Re: wxquake.php not working
« Reply #9 on: July 09, 2019, 10:28:31 PM »
Harry, the issue with your quake-json is it's at V1.12 - 21-Feb-2017 and the current release is V2.00 - 10-May-2018

The Old version used Google maps.. the V2.0 version uses Leaflet/OpenStreetmaps AND https to a newer URL at the USGS for content.

Update your script from https://saratoga-weather.org/scripts-quake.php#quakePHP and it should start working again.
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline Harry

  • Posts: 792
  • Union City, CA USA
  • OS/Browser:
  • Win NT 10.0
  • Firefox 67.0
    • Union City, CA Weather
Re: wxquake.php not working
« Reply #10 on: July 10, 2019, 12:52:01 AM »

^ Oops!  Okay, Ken.  Will update ASAP.  Thanks.

Offline Harry

  • Posts: 792
  • Union City, CA USA
  • OS/Browser:
  • Win NT 10.0
  • Firefox 67.0
    • Union City, CA Weather
Re: wxquake.php not working
« Reply #11 on: July 10, 2019, 07:42:29 PM »
Ken, I copied over the V2.00 quake-json.php file and still getting just the header.  Is there something else I need to change?

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • Win NT 10.0
  • Firefox 68.0
    • Saratoga Weather
Re: wxquake.php not working
« Reply #12 on: July 10, 2019, 08:48:18 PM »
Umm.. yes, there are multiple files to replace:

quake-json.css
quake-json.js
quake-json.php
quakes.php   (which is the model standalone page)
./ajax-images/layers*.png
./ajax-images/mma*.png

Optional:
wxquake.php  (how it works in a Saratoga template).


Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates

Offline Harry

  • Posts: 792
  • Union City, CA USA
  • OS/Browser:
  • Win NT 10.0
  • Firefox 67.0
    • Union City, CA Weather
Re: wxquake.php not working
« Reply #13 on: July 10, 2019, 09:17:32 PM »
I copied over all those files plus the images and I was getting files not available for a while and now, I just get the header.

Offline saratogaWX

  • Global Moderator
  • Posts: 5,939
  • Ken True
  • Saratoga, CA, USA 37:16:28N, 122:01:23W - Elev: 374ft.
  • OS/Browser:
  • Win NT 10.0
  • Firefox 68.0
    • Saratoga Weather
Re: wxquake.php not working
« Reply #14 on: July 10, 2019, 09:35:10 PM »
It's getting content .. the JSON file is 7827375 bytes (WOW!)

The problem may be with your version of PHP being unable to json_decode that amount of data.

On my PHP 7.3.7, it handles the decode just fine
Code: [Select]
<!-- content length=7828136 -->
<!-- found 10012 earthquake records -->

The Headers on your site show PHP/5.5.22  -- I think that versions prior to 5.6 had issues with decoding large JSON files into arrays.  Check your Apache error_log for info.. likely the script 500-Server error at the json_decode() command.   

Due to the recent earthquakes in CA, the JSON is much larger than usual, and I fear that the only way for your site to work with the updated scripts, is to update PHP to 5.6+ or 7.2+
Ken True
Saratoga Weather
CWOP: CW1792
WeatherUnderground: KCASARAT1
Free weather website PHP scripts and WD website AJAX templates