- As always support for Leuven template/scripts at: https://support.leuven-template.eu/
- Your forecast retrieves the data from two NWS sources,
- Point-Click part with the texts, in a state of flux since April 2017, nobody knows if and when the final version will be OK
- Detailed forecast, available from the SOAP server, which has had some rare but irritating access errors, mostly at nighttime
- You can always check if the problem is with your script or your area/NWS office by visiting the latest beta version of the Leuven scripts at https://www.weerstation-herent.be/saratoga/wsfct4/
The change from old to new NWS data-servers is postponed multiple times. First one April 2017, xx , xx , xx and now no new date is available anymore.
Solution: If you only want NWS forecasts
Better take a look of forecasts which use another data-source. They change their API also once or twice a year, but that will not happen at the same time.
Use one script which uses NWS
and another script for WU data (example:
http://saratoga-weather.org/scripts-WUforecast.php#WUforecast)
You could integrate them in a nice iFrame and use a switch to display only one of them. If the NWS script has a problem => use WU. And the other way around.
Current problem at
http://mid-southweather.com/forecast.htmlError message when retrieving the "point-click" forecast: No data was retrieved for
http://api.weather.gov/gridpoints/MEG/64,63/forecastThe scripts has to load 3 or 4 different files to arrive at the forecast and weather-warnings.
The first JSON file has the link to the second and following links
1.
https://api.weather.gov/points/35.07,-89.736 If you execute them in your browser you see the next links to access:
2.
http://api.weather.gov/offices/MEG => used for the issuing office and general info.
and the forecast link
3.
http://api.weather.gov/gridpoints/MEG/64,63/forecastThe NWS server itself supplies those links with
http :// But the beta-NWS sever rejects since a few days that link with a "301 Permanently moved message"
The retrieval script has to be made aware for that. It is a minor security risk, so it is switched off by default.But this script only accepts forecast data in JSON format.
Add the following line in your script before you load my script:
$curlFollow = 1;
Wim
P.S. This is the first data set retrieved at
https://api.weather.gov/points/35.07,-89.736 , it has only http links:
"properties": {
"@id": "http://api.weather.gov/points/35.07,-89.736",
"@type": "wx:Point",
"cwa": "MEG",
"forecastOffice": "http://api.weather.gov/offices/MEG",
"gridX": 64,
"gridY": 63,
"forecast": "http://api.weather.gov/gridpoints/MEG/64,63/forecast",
"forecastHourly": "http://api.weather.gov/gridpoints/MEG/64,63/forecast/hourly",
"forecastGridData": "http://api.weather.gov/gridpoints/MEG/64,63",
"observationStations": "http://api.weather.gov/gridpoints/MEG/64,63/stations",