I have a question. I got setup with PWSweather and xweather. I got the key and it seems to be working. My question is the small block in the upper left top of my dashboard that will display warnings, I’ve noticed other people are able to fill that space with a forecast. Currently mine says “have a nice day” Can anyone point me to where I should be looking to add that?
@ ALL Before asking always test a block in . . /pwsWD/PWS_module_test.php
There are drop-downs to select any block one can use.
In the area at the bottom, the unformatted block-html , optional error-messages and other information such as untranslated texts are displayed.
@ RidgeRunner260
When testing the block an error is returned.
Notice: date_default_timezone_set(): Timezone ID 'America/New York'
is invalid in /home/rpksthmhzp2y/public_html/pwsWD/nws-alerts/nws-alerts.php on line 122
So check your settings in the . . /nws-alerts/ scripts.
The setting for the timezone is in or around line 35 of nws-alerts-config.php
The correct timezone can be found in the PHP-documentation
→ https://www.php.net/manual/en/timezones.php
For New York it is America/New_York
so replace the space in your setting with an _
The advisory_c_small block can return a 1 hour forecast if there is no other more important information.
That 1 hour forecast is loaded from either a DarkSky-alternative, WeatherUnderground, WXSIM or EnvironmentCanada forecast.
Currently there is no script to load it from an Aeris forecast.
If there is no other more important information, the translated “Have a nice day” is displayed.
regards,
Wim
OK so I can’t fix the time zone until I get home later today. I’ll look into that later.
With regards to the 1 hour forecast. So to get the 1 hour forecast into the small block. I would have to switch from xweather to one of the ones you mentioned like Darksky.
I do currently have a 1 hour forecast from xweather, but in one of my large blocks.
From the start of pwsWD we used DarkSky, WU and WXSIM for 1 hour forecasts.
It is not a trivial task to add Aeris and you are the first one to bring this “problem” forward.
It will take enough spare time to adept the scripts to read the data from the Aeris forecast. And to test it.
I post a new answer probably Wednesday.
Wim
This is a beta version of the adapted advisory_c_small block.
It is added as last entry so it will be used only if there are no other sources for the data.
I need more time to check for conflicts, will do that tomorrow.
Install:
- Make a backup of the current advisory_c_small block.php
- Unzip and upload this version.
Test:
If there are problems
- Make a screenshot or copy the messages
- rename the new version as problem.php and
- use the backup you made in point 1.
advisory_c_small.php.zip (4.8 KB)
OK so is thing something for me to test? If so I can do this later this evening when I am home.
Yes you and others can test it, if you make copy of the current version to use if there are strange problems.
Using WU (as I do for the advisory block) you get the current WU text forecast for today/tonight. Does that change every hour?
Done! looks good, have a look for yourself.
no errors looks good!
The data is reloaded from WU every 900 seconds.
Whether the content changes for the current day/night and how often is not documented, I could not find that anyway.
Kind regards,
Wim
Seems to be working fine.
You can see here:
Sherman Connecticut Home Weather Station (cumulus version) (shermanctweather.org)
The forecast in your advisory block looks like WXSim, not Aeris. That has always been available.
Changed to Aeris. Working fine.
Tom