Customising PWS Dashboard (early versions)

I have been modifying blocks and pop-ups since the original release [1901], but lately I have been experimenting with 4 rows of 3 blocks. With help and encouragement from Wim, I managed to “go live” this morning (link under avatar).

Only two files need to be changed: I had worked out how to add the extra blocks in w34_index.php, and Wim told me I had to add them in w34_updater.php as well. They cannot be changed with easyweathersetup because the block positions are defined, just as rows 1 and 2 of main blocks.

I had added a number of extra pop-up “buttons” which are now surplus to requirements, and I expect I shall make further changes to the layout, but in the meantime I thought I’d share it for discussion.

LATER EDIT: This thread describes my changes to Wim’s original version (January 2019) up to and including Reply #37 on page 3, when I started fiddling with the July 2019 version that I still use (globe link at left in Profile). The original version can still be seen working under Menu > Original release.

Looks great, nice work!

This is very nice.

I looked at your home page and it is very well balanced, a beautiful layout without being overly glitzy.

I know as soon as folks start modifying things, the future releases from the author will likely be in trouble or require updating that release before your modifications can work.

Is the whole process difficult if new releases come along just occasionally rather than regularly?

Is it a Herculean task or possible for others to try?

Thanks for the update and you should be proud of your work.

Very nicely done :thumbright:


Where did you get access to the code to study and know where to put stuff into?

Being new to this, I’m not sure how to get the code that needed to be adapted.

It may be illuminating to look through it to see how this works.

Thanks, guys.

@Tlowe: until recently I ran the same old version as you, with the small extrasensor block. That’s what started me off, so I could display extratemp/hum. Added garden_temp and hum to w34_livedata.php, copied indoor_block.php and changed “indoor” to read “garden”. . . never looked back.

@Dale Reid: I first learned to program a computer in the early '60s, and I stopped with BASIC in the '80s. But if you are logical, change only one thing at a time, and make sure you always keep a copy of the original/last known good version, you can figure out how to modify someone else’s hard work: I didn’t write a single original bit of code. Notepad++ is your best friend. Wim would probably be horrified, but he made encouraging noises: I promise not to ask him for support if my changes fall over.

BTW, I can’t answer your question about new releases. . . I might not bother with them :slight_smile:

@niko: I couldn’t have done it without your help!

@bitsostring =D>


How about a screen filling, no scroll, 3 rows of 4 next :wink:

Funny you should say that. . .

Just trying to work out how to get 5 small modules across the top of 4 big ones :lol:

Added a new pop-up - UV Index | Cloudbase - which is an attempt to combine the left half of the uvsolarlux pop-up with the left half of an AQ pop-up because I don’t have solar or AQ. . . (You can still see the original pop-ups, now labelled UV Index and Cloudbase.)

Obviously, I haven’t quite mastered the CSS for the cloudbase half. . . work in progress :slight_smile:

I’ve been looking at the latest release and I’m not going to use it. That’s not a criticism - I’ve spent 3 months customising the original release and it does what I need it to do and looks (nearly) how I want it to, so I think I’ll wait until “the basic scripts all work” (as Wim says) before I start tinkering again. . .

Very nice I like it a lot.


Added Norwegian language support. Thanks, Torjan & Wim :slight_smile:

Only minor changes to report: I’ve given up on 3 rows of 4, Wim does it so much better!

Got max-min temp times showing in the small temp window; went back to the earlier sun block theme using a grey segment (and sun) for night; copied latest yellow segment idea for moon luminance, but also changed the text colour in css and went to grey for the rest of the circle; and did a lot of fiddling in metar pop-up, e.g. to get rid of brackets round units and to add a bit more info.

All this on the original January release.

Managed to get a small max-min extratemp block working, but I must be doing something wrong because it always shows °C

Salutory lesson: fiddled with w34_livedata.php last night to sort rain rate units, but I wasn’t working on the latest version of the script so the small extratemp block stopped working overnight :roll:

Recently noticed that my barometer block (original release) doesn’t switch between UK and US units properly: the main pressure reading, the max/min for the day and the trend change OK, but the dial limits and conversion at bottom left do not.

I had made a few changes to barometer_block.php, so I went back to the original (19/01 update) version and it still doesn’t work. AFAIK I haven’t made any changes to pressure values in w34_livedata.php. . .

EDIT: found the reason for that conversion problem was a small routine I added to lines 345-53 of w34_livedata.php to get max/min extratemps from a customtextout file. Now I need to understand why what I did there upset the temp_unit conditionals in barometer_block :frowning:

Can the fact that w34_livedata.php defines $weather[“temp_units”] = “C” while the conditionals are if ($weather[“temp_units”] == ‘C’) have anything to do with it. . .?

Single vs. double quotes should make no difference when used like that with simple strings.

Thanks - I just tried it and came to the same conclusion! Back to square one.

P.S. I’m sure you’ve told me that before. . . I’ll try to remember from now on :wink: