Welcome to the Cumulus Support forum.

Latest Cumulus MX V3 release 3.28.6 (build 3283) - 21 March 2024

Cumulus MX V4 beta test release 4.0.0 (build 4017) - 17 March 2024

Legacy Cumulus 1 release v1.9.4 (build 1099) - 28 November 2014 (a patch is available for 1.9.4 build 1099 that extends the date range of drop-down menus to 2030)

Download the Software (Cumulus MX / Cumulus 1 and other related items) from the Wiki

Cumulus ‘Current Conditions’ Alternative v3.0

Other discussion about creating web sites for Cumulus that doesn't have a specific subforum

Moderator: daj

User avatar
beteljuice
Posts: 3292
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: W10 - Threadripper 16core, etc
Location: Dudley, West Midlands, UK

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by beteljuice »

OK - your converted _apptemp is:
<!-- _apptemp: -4 C -->
The code says:

Code: Select all

        } elseif ($_apptemp >= -10.0 && $apptemp < 0.0){
            $CI_text = $langCurrComfort[3]; 
The array should be:

Code: Select all

$langCurrComfort = array (
   "DANGEROUSLY COLD", "Extremely Cold", "Bitterly Cold", "Very Cold", "Uncomfortably Cold", "Cold", "Cool", "Coolish", "Mild", "Warm", "Very Warm", "Hot", "Uncomfortably Hot", "Very Hot", "Extremely Hot", "DANGEROUSLY HOT");
So your output should be "Very Cold"

What's been changed ?
Image
......................Imagine, what you will KNOW tomorrow !
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

Errors all fixed and hopefully we are back on track :)

The 3 versions have been repacked and uploaded.

Thanks bnwrx for helping sort out your dangerously hot weather at -4.0 °C (26.8°F)

Cheers
Jenny
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
User avatar
beteljuice
Posts: 3292
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: W10 - Threadripper 16core, etc
Location: Dudley, West Midlands, UK

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by beteljuice »

@everyone

Jenny fixed it Image ... and it was a beteljuice problem :oops:

Just in time for you all to 'Prefix' with Happy Christmas ;)
Image
......................Imagine, what you will KNOW tomorrow !
bnwrx
Posts: 464
Joined: Wed 25 Feb 2009 12:01 am
Weather Station: Ambient WS2095 (Fine/Offset)
Operating System: Windows 10 64bit
Location: Woodland Park, Colorado USA
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by bnwrx »

I can confirm also for all "F" users, it now works!!! :clap: :clap:

Many thanks to beteljuice and jenny!!!
User avatar
beteljuice
Posts: 3292
Joined: Tue 09 Dec 2008 1:37 pm
Weather Station: None !
Operating System: W10 - Threadripper 16core, etc
Location: Dudley, West Midlands, UK

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by beteljuice »

I think perhaps that so far the 'optional' Admin Modifier hasn't been appreciated and is a worthwhile and powerful thing .....

Comments within the script:

Code: Select all

Options:
   Auto - default behaviour fully automatic best guess current conditions.
   Manual - Completely REPLACES Auto with the specified text for the specified amount of time, then returns to Auto
   Prefix - Specified text is put in front of Auto for the specified amount of time, then returns to Auto
   Hybrid - As for Prefix BUT rain reporting (If applicable) is removed for the specified amount of time, then returns to Auto
            this is useful eg. snow / hail when your bucket reports nothing until a thaw then says you have a monsoon with clear skies
So you could for example put "Merry Christmas" or "Webcam broken" or ..... whatever in front of the conditions text.

If your weather station is temporarily 'sick' you can suppress the (Incorrect) conditions text and optionally replace it with eg. "Anemometer frozen"

... and so on.

Everything (except Auto ;) ) can be given a "Time To Die" or "Never" so that you don't have to remember to remove a temporary comment.

For those using Multi-Lingual templates (eg. Saratoga ML or WeatherByYou ML) the script will try to do a best guess translation of your comment !

Edit: Google have removed the free translator that was being used :(

.... and for those using saratoga ML, we've even enabled a little used feature in the footer that shows you all the (saratoga) missing translations for the page language.

What more do you want :clap: (That is rhetorical by the way and not a request for even more coding :bash: )
Last edited by beteljuice on Sun 22 Sep 2019 2:19 am, edited 1 time in total.
Image
......................Imagine, what you will KNOW tomorrow !
bnwrx
Posts: 464
Joined: Wed 25 Feb 2009 12:01 am
Weather Station: Ambient WS2095 (Fine/Offset)
Operating System: Windows 10 64bit
Location: Woodland Park, Colorado USA
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by bnwrx »

beteljuice wrote:....What more do you want :clap: (That is rhetorical by the way and not a request for even more coding :bash: )
But we do want more, more, more.....Figgy Pudding that is!! :lol: :lol:

Seriously though...This is really great work by beteljuice and Jenny....
I've been using it, and yes, using the Modifier, and I can insert a brief comment about what is happening at the moment, and have it time out and not worry about it not being "quite accurate", if you catch my drift.
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by water01 »

OK is it me being thick but I cannot see why the instructions say
Add both CCdataT.php and CCdata.php files to 'cumulus\web' folder.
Surely I only need either CCdataT.php or CCdata.php and upload which ever one you choose, after processing, as CCdata.php?
David
Image
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

Surely I only need either CCdataT.php or CCdata.php and upload which ever one you choose, after processing, as CCdata.php?
HI David,

'To my knowledge' you need both in your cumulus folder. CCdataT.php to be processed to CCdata.php. CCdata.php to be uploaded.
Just the same as the Cumulus standard pages, you dont want the original file with the tags over written.

Looks neat on your website David. Have a play with the currAdminML.php

Cheers
Jenny
Last edited by JennyLeez on Tue 23 Dec 2014 10:02 pm, edited 1 time in total.
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

So you could for example put "Merry Christmas" or "Webcam broken" or ..... whatever in front of the conditions text.
I have just played beteljuice.
My standalone/own design site also allowed me to add styling to Manual to change the Merry Christmas to bold and red.
http://wairoa.net/weather/index.htm
For those using Multi-Lingual templates (eg. Saratoga ML or WeatherByYou ML) the script will try to do a best guess translation of your comment !
I also tried styling with the Saratoga template which worked in english but alas in other ML languages it tried to translate the code :)
So I reverted back to no styling and all is well.
http://wairoaweather.net/CCmodifier.php

21 languages all saying Merry Christmas, you are pretty clever beteljuice :)

http://wairoaweather.net/?lang=en
http://wairoaweather.net/?lang=fr
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by water01 »

'To my knowledge' you need both in your cumulus folder. CCdataT.php to be processed to CCdata.php. CCdata.php to be uploaded.
Just the same as the Cumulus standard pages, you dont want the original file with the tags over written.
I think you are wrong Jenny. Cumulus automatically processes CCdata.php to CCdata.phptmp and that gets uploaded as CCdata.php. The T files in the standard Cumulus web are simply to maintain any customised amendments made to the Templates which are then uploaded as standard to the files without the T in Steve's code, you do not need this if you are processing a file via the Files area as Cumulus automagically takes care of the tmp for you.

Therefore there is no need to have both files as my site proves because I am processing CCdata.php and uploading it I have not bothered with the CCdataT.php file.
David
Image
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

Hi David,

Live and learn on my part :)
But for single upload only.

That would not work for me though. I also need CCdataT.php processed and stored on my hard drive as CCdata.php to allow another FTP program to upload it to a different server. I am feeding a few demo sites at present :) So yes I do need both.

Many of us have more than 1 web sites so I think I will leave the packages as is for clarity.

Thanks for you help David :)

Cheers
Jenny
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
User avatar
PaulMy
Posts: 3775
Joined: Sun 28 Sep 2008 11:54 pm
Weather Station: Davis VP2 Plus 24-Hour FARS
Operating System: Windows8 and Windows10
Location: Komoka, ON Canada
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by PaulMy »

I think perhaps that so far the 'optional' Admin Modifier hasn't been appreciated and is a worthwhile and powerful thing .....
I've been playing with trying this for a couple of things already such as Notice that EC forecasts were not available, and also the colour Merry Christmas looks nice!

Great idea,
Paul
Davis Vantage Pro2+
C1 www.komokaweather.com/komokaweather-ca
MX www.komokaweather.com/cumulusmx/index.htm /index.html /index.php
MX www.komokaweather.com/cumulusmxwll/index.htm /index.html /index.php
MX www. komokaweather.com/cumulusmx4/index.htm

Image
water01
Posts: 3215
Joined: Sat 13 Aug 2011 9:33 am
Weather Station: Ecowitt HP2551
Operating System: Windows 10 64bit
Location: Burnham-on-Sea
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by water01 »

That would not work for me though. I also need CCdataT.php processed and stored on my hard drive as CCdata.php to allow another FTP program to upload it to a different server. I am feeding a few demo sites at present :) So yes I do need both.
Since Cumulus doesn't delete CCdata.phptmp, instead of processing two files why don't you just upload that file and change its name to CCdata.php, which would save Cumulus the extra file process.
David
Image
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

I tried that from your previous post if this is what you mean.

program files\cumulus\CCdata.phptmp --> /CCdata.php

It would not upload and overwrite like that unfortunately.
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
User avatar
JennyLeez
Posts: 314
Joined: Wed 16 Dec 2009 2:32 am
Weather Station: La Crosse WS3083
Operating System: Windows XP, Win7 & Win 10
Location: Wairoa, Hawkes Bay. New Zealand.
Contact:

Re: Cumulus ‘Current Conditions’ Alternative v3.0

Post by JennyLeez »

PaulMy wrote:
I think perhaps that so far the 'optional' Admin Modifier hasn't been appreciated and is a worthwhile and powerful thing .....
I've been playing with trying this for a couple of things already such as Notice that EC forecasts were not available, and also the colour Merry Christmas looks nice!
Great idea,
Paul
Looks neat Paul, did you have a look at it in French though.
Thats what happened to me also so I took the colour away :)

Cheers
Wairoa, Hawkes Bay, New Zealand Weather Station:
http://wairoa.net/weather/index.htm
Cumulus Topsites:
http://cumulussites.net/
Image
Post Reply