Trixology

WeatherCat => WeatherCat Web Templates => Topic started by: saratogaWX on March 15, 2012, 07:09:10 PM

Title: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 15, 2012, 07:09:10 PM
Hi folks!

Stu had asked me if it were feasible to create a Plugin for my AJAX/PHP template sets (http://saratoga-weather.org/wxtemplates/index.php) to work with WeatherCat, and ... yes, it is very feasible, and I've started construction of the Plugin.

I hope to have it available in less than one week from now.

I do have WeatherCat Beta running on my iMAC and creating data from my Davis VP+ station, and already have the PHP tags file pretty much finished.  The only 'issue' I'd found so far is how to handle the '$' tag delimiter and not have PHP be confused by a missing variable name (PHP uses $ at the start to indicate a variable name). 

I'll keep you posted on the progress.  Thanks Stu, for asking in the first place :)

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 15, 2012, 07:17:57 PM
Welcome Ken, and on behalf of all the WeatherCat users, thank you for taking the time to do this!

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 15, 2012, 08:06:48 PM
Thanks for joining us, Ken, and I'm glad to see your interest here. We'd talked to you about this with Stu's prior weather application, LWC a while back on the MacWeather forum, and last week I'd mentioned you might be interested in getting us going on WeatherCat with your templates, so I'm glad Stu contacted you.

I've been fiddling with the WeatherSnoop version on a trial copy of WeatherSnoop. I have it getting data from WeatherCat's feed to Weather Underground. Definitely a round about way to get there. I'm looking forward to adding some of the features of your templates to my web site.

Thanks,
Steve
Title: Thank you!! (Re: New Saratoga AJAX/PHP template)
Post by: elagache on March 16, 2012, 02:08:25 AM
Welcome Ken!!

Let me join the chorus thanking you for your efforts at supporting da' Cat!  [cat]

Much appreciated!!  [tup]

Cheers, Edouard  [cheers1]
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: jace on March 16, 2012, 11:48:56 AM
Where do I sign up for web page design and Applescript lessons  [tup] [banghead]

JC
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 16, 2012, 04:13:49 PM
Thanks for the warm welcome!  I'm very pleased to help WeatherCat enthusiasts be able to use a modular AJAX/PHP template design.  WeatherCat will be the 7th weather software package to use the template set -- and over 600 websites have used the free template set as a starting point for their personal weather websites around the world.

I've got a working copy (testing version) up at http://saratoga-weather.org/wxtemplates/Test/wxindex.php if you'd like to 'kick the tires' on my development copy.

Currently, WeatherCat is uploading the tags file (see dump (http://saratoga-weather.org/WeatherCat/WCTtags.php?sce=dump), see source (http://saratoga-weather.org/wxtemplates/WeatherCat/WCTtags.php?sce=view)) with weather from my station, and the defs file (see source (http://saratoga-weather.org/wxtemplates/Test/WCT-defs.php?sce=view)) maps the $WX[] variables to the $variables needed for the display in the dashboard/gizmo area.  I'll be adding the AJAX script as I figure out how to upload one file more frequently than 5 minutes (like every 15 seconds).

I'll keep you posted on progress, and suggestions are always welcome!

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: tigers on March 16, 2012, 04:39:11 PM
Thanks for the warm welcome!  I'm very pleased to help WeatherCat enthusiasts be able to use a modular AJAX/PHP template design.  WeatherCat will be the 7th weather software package to use the template set -- and over 600 websites have used the free template set as a starting point for their personal weather websites around the world.

I've got a working copy (testing version) up at http://saratoga-weather.org/wxtemplates/Test/wxindex.php if you'd like to 'kick the tires' on my development copy.

Currently, WeatherCat is uploading the tags file (see dump (http://saratoga-weather.org/WeatherCat/WCTtags.php?sce=dump), see source (http://saratoga-weather.org/wxtemplates/WeatherCat/WCTtags.php?sce=view)) with weather from my station, and the defs file (see source (http://saratoga-weather.org/wxtemplates/Test/WCT-defs.php?sce=view)) maps the $WX[] variables to the $variables needed for the display in the dashboard/gizmo area.  I'll be adding the AJAX script as I figure out how to upload one file more frequently than 5 minutes (like every 15 seconds).

I'll keep you posted on progress, and suggestions are always welcome!

Best regards,
Ken

Good to see you here. Your templates were the inspiration I needed to kick off my own template project although I'm not sure my template will be nearly as comprehensive as yours!

As for real time data, you can use the cgi tab and get the updates that way. I'm using this to generate an XML file which I'm then reading into my template via Ajax. Currently I've got the update interval at 5 seconds and it seems to work well.

I'm going to ask Stu if the real time data can be expanded a bit to include highs,lows, and the times for those.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 16, 2012, 04:57:23 PM
Thanks for the tip about the CGI upload .. that sounds quite workable, and I hope Stu does add in today's high/low temperatures and times to the mix.   I'll give that a try with a modified submit script :)

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 16, 2012, 06:07:59 PM
Let me know what you need folks and I can get it into the development plan.

Ken, for individual uploads please see the 'Additional Files' tab in the Custom Web preferences - here you can add files that are processed individually on their own time schedule.

Nice work  [tup]

Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 16, 2012, 08:30:55 PM
Let me know what you need folks and I can get it into the development plan.

Ken, for individual uploads please see the 'Additional Files' tab in the Custom Web preferences - here you can add files that are processed individually on their own time schedule.

Nice work  [tup]

Stu.

Thanks Stu!

It would be nice to have STAT$TEMPERATURE:DELTA24$ to return the outside temperature 24hrs ago.

I'll give a try to the Additional Files to upload a WCT_realtime.txt file for the AJAX script ..

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 16, 2012, 08:58:06 PM
Ken,

What's nice with the CGI export is that it sends out only raw date every few seconds rather than a template every however seconds/minutes for the 'Additional Files', keeping bandwidth tidy. (unless you are processing locally and sending converted raw data every few seconds.)

Steve
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 16, 2012, 09:01:20 PM
Hi Ken,
Thanks for the feedback.

I'll add a counterpart to CURRENT which will be 24HRSAGO - this will return the data as it was 24 hours ago. I'll also add DELTA24 which will return the difference between the data 24 hours ago and now (this fits in with DELTA1).

I should be able to get these into the next build (out in a few days).

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: tigers on March 16, 2012, 10:21:33 PM
 Stu, I'd also like to request the high and low temps for the day and the time they occurred. Hopefully this won't turn unwieldy from your end.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 16, 2012, 10:22:52 PM
Hi Ken,
Thanks for the feedback.

I'll add a counterpart to CURRENT which will be 24HRSAGO - this will return the data as it was 24 hours ago. I'll also add DELTA24 which will return the difference between the data 24 hours ago and now (this fits in with DELTA1).

I should be able to get these into the next build (out in a few days).

Cheers,
Stu.

Awesome, Stu!

Would it also be possible to add a 24hr time with hh:mm:ss in it (instead of just hh:mm?  That would help with the AJAX updates (which are now pegged at 1 minute since no :ss available on the time).  This could be a new tag so the t24$ wouldn't have to change if you didn't want it to.  A similar new tag for h:mm:ss AM/PM (to augment t12$ would also be useful.

A 'date/time of last rain gauge tip' tag would be helpful too (ISO YYYY-MM-DD HH:MM:SS would be great).  This can be used to compute 'days since last rain'.

I see that all the date tags come out as 'dd MON yyyy', but there doesn't seem to be a setting preference to have them in dd/mm/yyyy or mm/dd/yyyy format.  Is that a system-wide option, or something that could be added?  The reason is that the MON (if it comes from the system) may be in a non-English locale which would make it difficult to handle with PHP (which runs English).  If it is a system-wide thing, then another option would be to add a tag that would have the month-name abbreviations used on the system like

Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec

Then I could convert to English for processing even if the Mac were running with a different language default.

BTW... I now have AJAX updates on the test site.  I am using the Additional Files upload for a small tags file (based on the Cumulus realtime.txt) handled by an ajaxWCTwx.js AJAX script (oddly enough, based on the Cumulus script too :) )

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 16, 2012, 11:07:28 PM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.


Ken, I understand your problems :)

My preliminary suggestion is to add a tag that switches the web processing from human readable/localised date/time formats to a more machine readable format. I would suggest ISO 8601 - i.e. YYYY-MM-DD and times as hh:mm:ss (24 hour format)). Dates/times are separated by the character 'T'.

A full date/time would be of the format: YYYY-MM-DDTHH:MM:SS - i.e. 2012-03-16T22:48:14

So if WeatherCat sees ISO8601DATES$ from that point on until the end of the page (or HUMANDATES$) it switches to the ISO 8601 format for dates and times. Fixed format tags such as t12$ are excluded, I'll also add t12s$ and t24s$ which output with seconds and similarly are excluded.

(Note, I am not in front of the WeatherCat code at the moment (I'm actually deep into www.F1.com getting ready for the season), but I don't think it'll be too difficult to do this).

Would that cover your requirements?

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 16, 2012, 11:17:24 PM
Todd, Ken - this is development how I like it  :)

Ken, I understand your problems :)

My preliminary suggestion is to add a tag that switches the web processing from human readable/localised date/time formats to a more machine readable format. I would suggest ISO 8601 - i.e. YYYY-MM-DD and times as hh:mm:ss (24 hour format)). Dates/times are separated by the character 'T'.

A full date/time would be of the format: YYYY-MM-DDTHH:MM:SS - i.e. 2012-03-16T22:48:14

So if WeatherCat sees ISO8601DATES$ from that point on until the end of the page (or HUMANDATES$) it switches to the ISO 8601 format for dates and times. Fixed format tags such as t12$ are excluded, I'll also add t12s$ and t24s$ which output with seconds and similarly are excluded.

(Note, I am not in front of the WeatherCat code at the moment (I'm actually deep into www.F1.com getting ready for the season), but I don't think it'll be too difficult to do this).

Would that cover your requirements?

Cheers,
Stu.
Stu, that would work just fine for the dates (ISO8601DATES$ to start the machine-friendly dates, HUMANDATES$ to end, and ISO dates in YYYY-MM-DDTHH:MM:SS format in local time)

Thanks,

Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: tigers on March 16, 2012, 11:44:56 PM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.

Cheers,
Stu.

Well since you asked ;D

1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
5. Daily High External Barometer (inhg)
6. Time of above
7. Daily Low External Barometer (inhg)
8. Time of above
9. High windspeed for the day
10. Time of above

Thanks Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 17, 2012, 12:43:35 AM
(I'm actually deep into www.F1.com getting ready for the season)

You are now officially my favorite developer ever! :D Are you a de Resta fan? Long time Webber fan, here (well, long time Rubio fan, but...)

Just finished watching the DVR'd Friday Practice #2.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 09:13:51 AM
Todd, Ken - this is development how I like it  :)

Ken, I understand your problems :)

My preliminary suggestion is to add a tag that switches the web processing from human readable/localised date/time formats to a more machine readable format. I would suggest ISO 8601 - i.e. YYYY-MM-DD and times as hh:mm:ss (24 hour format)). Dates/times are separated by the character 'T'.

A full date/time would be of the format: YYYY-MM-DDTHH:MM:SS - i.e. 2012-03-16T22:48:14

So if WeatherCat sees ISO8601DATES$ from that point on until the end of the page (or HUMANDATES$) it switches to the ISO 8601 format for dates and times. Fixed format tags such as t12$ are excluded, I'll also add t12s$ and t24s$ which output with seconds and similarly are excluded.

(Note, I am not in front of the WeatherCat code at the moment (I'm actually deep into www.F1.com getting ready for the season), but I don't think it'll be too difficult to do this).

Would that cover your requirements?

Cheers,
Stu.
Stu, that would work just fine for the dates (ISO8601DATES$ to start the machine-friendly dates, HUMANDATES$ to end, and ISO dates in YYYY-MM-DDTHH:MM:SS format in local time)

Thanks,

Ken

Thanks Ken - I'll get those changes into the next release.
Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 09:16:48 AM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.

Cheers,
Stu.

Well since you asked ;D

1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
5. Daily High External Barometer (inhg)
6. Time of above
7. Daily Low External Barometer (inhg)
8. Time of above
9. High windspeed for the day
10. Time of above

Thanks Stu.
Ok Todd, I'll get them into the next release.

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 09:20:18 AM
(I'm actually deep into www.F1.com getting ready for the season)

You are now officially my favorite developer ever! :D Are you a de Resta fan? Long time Webber fan, here (well, long time Rubio fan, but...)

Just finished watching the DVR'd Friday Practice #2.

Lol, no, I wouldn't say I'm a fan of any one in particular - this season it's more a case of seeing if anyone can challenge Vettel for the title - I do hope so! (Not that I don't like him, just that a third Red Bull season would be a little boring...).

Cheers,
Stu.

Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 17, 2012, 05:49:12 PM
Ken,

Is Scott's soil temp/moisture page part of your template or is that part of Brian's WD?

Scott's page: http://www.websterweatherlive.com/wxsoil.php

Thread: http://www.wxforum.net/index.php?topic=13073.0

I'm testing/reviewing a Davis station now, so it might be interesting to have the info to share.
http://athena.trixology.com/index.php?topic=136.0

Thanks,
Steve
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 17, 2012, 06:38:22 PM
Ken,

Is Scott's soil temp/moisture page part of your template or is that part of Brian's WD?

Scott's page: http://www.websterweatherlive.com/wxsoil.php

Thread: http://www.wxforum.net/index.php?topic=13073.0

I'm testing/reviewing a Davis station now, so it might be interesting to have the info to share.
http://athena.trixology.com/index.php?topic=136.0

Thanks,
Steve
Hi Steve,

The wxsoil.php is (AFAIK) a add-on page to the templates, primarily for Weather-Display users only.  Scott (WebsterWeather) has made some amazing add-ons for the template, but.. they apply mostly to WD users (alternative dashboard, etc).

Where there are extra sensors on a station, there's nothing to prevent folks from adding tags to the WCTtags.php template and adding $tagname = $WX['...']; statements to the WCT-defs.php file to enable the display of those extra sensors.

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 17, 2012, 08:36:47 PM
Thanks for the explanation. I'll play with that once I get things set up in their final location with the Soil Staion.

Thanks,
Steve
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 09:31:35 PM
Hi Ken,
Due to the way templates are parsed, there was no easy way for me to serialise the parsing so that one could switch the iso 8601 dates/times on and later switch them off further down the page.

What I've done is if ISO8601DATES$ is found anywhere on the page (I run a pass  for it first), all STAT$ type tags on that page will output ISO dates/times - is this OK for you? I've also added 24HRSAGO$ and DELTA24$ along with t12s$ and t24s$ which output with seconds - these are currently on test at http://www.trixology.com/live_weather/custom/

Let me know if that gives you any problems,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 17, 2012, 09:50:58 PM
Hi Ken,
Due to the way templates are parsed, there was no easy way for me to serialise the parsing so that one could switch the iso 8601 dates/times on and later switch them off further down the page.

What I've done is if ISO8601DATES$ is found anywhere on the page (I run a pass  for it first), all STAT$ type tags on that page will output ISO dates/times - is this OK for you? I've also added 24HRSAGO$ and DELTA24$ along with t12s$ and t24s$ which output with seconds - these are currently on test at http://www.trixology.com/live_weather/custom/

Let me know if that gives you any problems,
Stu.

Hi Stu,
Love the new 24HRSAGO$ and DELTA24$ variables.. very useful!  Also, the t12s$ and t24s$ too.   8)  ;D

I don't have an issue with ISO date/times appearing on all the STAT$...:TIME$ vars with ISO8601DATES$ on the page.  I don't see any samples of the ISO date format on your http://www.trixology.com/live_weather/custom/ page at this time.. all the STAT$ dates are appearing as dd MON yyyy hh:mm AM/PM right now   ???

Best regards,
Ken

BTW.. great FAST work .. I too, love interactive development :)
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 10:37:43 PM
I've switched them on now Ken. Give it a look and let me know if they look OK, then I'll switch them off again (don't want to frighten people :) )

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 17, 2012, 10:53:42 PM
I've switched them on now Ken. Give it a look and let me know if they look OK, then I'll switch them off again (don't want to frighten people :) )

Cheers,
Stu.

Yes!

Quote
Highest temperature today = STAT$TEMPERATURE:MAX:TODAY$TEMPUNITS$ at STAT$TEMPERATURE:MAX:TODAY:TIME$


Highest temperature today = 9.78?C at 13:48:00
Highest temperature yesterday = 10.17?C at 10:45:00
Highest temperature this week = 11.28?C on 2012-03-11T13:40:00
Highest temperature last week = 12.28?C on 2012-03-09T14:14:00
Highest temperature this month = 12.61?C on 2012-03-01T12:26:00
Highest temperature last month = 12.83?C on 2012-02-22T13:22:00
Highest temperature this year = 12.83?C on 2012-02-22T13:22:00
Highest temperature last year = 24.17?C on 2011-07-27T18:18:00
Highest temperature of all time = 29.50?C on 2009-07-02T14:59:00

...

Highest solar radiation today = 584.00 W/m^2 at 11:03:00
Highest solar radiation yesterday = 139.00 W/m^2 at 14:50:00
Highest solar radiation this week = 584.00 W/m^2 on 2012-03-17T11:03:00
Highest solar radiation last week = 494.00 W/m^2 on 2012-03-07T11:01:00
Highest solar radiation this month = 584.00 W/m^2 on 2012-03-17T11:03:00
Highest solar radiation last month = 397.00 W/m^2 on 2012-02-18T11:04:00
Highest solar radiation this year = 584.00 W/m^2 on 2012-03-17T11:03:00
Highest solar radiation last year = 1215.00 W/m^2 on 2011-06-10T13:24:00

will work just fine!   Thanks!!   [woohoo]
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 17, 2012, 11:02:25 PM
Thanks Ken.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 18, 2012, 10:33:29 PM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.

Cheers,
Stu.

Well since you asked ;D

1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
5. Daily High External Barometer (inhg)
6. Time of above
7. Daily Low External Barometer (inhg)
8. Time of above
9. High windspeed for the day
10. Time of above

Thanks Stu.
Ok Todd, I'll get them into the next release.

Cheers,
Stu.

Hi Todd,
I've made the changes we talked about, I've also added a few extras.

I've got it on test at:
http://www.trixology.com/live_weather/custom_cgi/watch_weather.php

I'm currently sending the data every 5 seconds (sadly the weather is pretty quiet here at the moment). All hi/lo times are sent as local.

[Edit: I wanted to add the 3 hour baro delta, but sadly ran out of time - maybe I'll get it in later in the week. I'm also going to drop the seconds from the high/low times]

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: tigers on March 18, 2012, 11:45:50 PM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.

Cheers,
Stu.

Well since you asked ;D

1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
5. Daily High External Barometer (inhg)
6. Time of above
7. Daily Low External Barometer (inhg)
8. Time of above
9. High windspeed for the day
10. Time of above

Thanks Stu.
Ok Todd, I'll get them into the next release.

Cheers,
Stu.

Hi Todd,
I've made the changes we talked about, I've also added a few extras.

I've got it on test at:
http://www.trixology.com/live_weather/custom_cgi/watch_weather.php

I'm currently sending the data every 5 seconds (sadly the weather is pretty quiet here at the moment). All hi/lo times are sent as local.

[Edit: I wanted to add the 3 hour baro delta, but sadly ran out of time - maybe I'll get it in later in the week. I'm also going to drop the seconds from the high/low times]

Cheers,
Stu.

Looking good! I had my page almost set to go but decided to blow it up and take a approach to it. Looking forward to incorporating this new data!
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 19, 2012, 07:42:53 PM
Hi Stu,

Any chance of releasing a build with the new features (t24s$, :24HRSAGO$, :DELTA24$ and ISO8601DATES$ ) enabled?
I'm finishing up the WCT-plugin + docs and need to test that they display as expected :)

I've added five custom pages to the template for WeatherCat users:

wxjournal.php - display the formatted Journal entries (with datestamps processed per Settings.php entries)
wxthismonth.php - display a formatted STMONTHLY$  (poor man's 'NOAA Style Climate Report')
wxyearoveryear.php - display a formatted STYEAROVERYEAR$ with translation ability
wxstationrecords.php - display the STRECORDS$
wxrecent.php - display the STRECENT$

See them in action (and the AJAX updates are working too) at
http://saratoga-weather.org/wxtemplates/Test/wxindex.php

I'm now finishing up the setup documentation for the WCT Settings-weather.php and WeatherCat preferences to make the templates work :)

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 19, 2012, 09:25:24 PM
Nice work Ken [tup] I've just been having a look around all the pages - very nice!

Unfortunately I can't send you a build just at the moment - the one I've just put on-line needs to soak test for 24 hours. If it's still running when I get home from work tomorrow, I'll send you a build then. I'm aiming the next public release at this weekend.

Cheers,
Stu.

Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 19, 2012, 09:27:34 PM
Todd, Ken - this is development how I like it  :)

Todd, I assume you're talking about the custom CGI? If so, if I can just spec the changes you want, they are:
1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
Let me know if this is OK.

Cheers,
Stu.

Well since you asked ;D

1. Add daily high external temperature  (Fahrenheit)
2. Add time of daily high external temperature
3. Add daily low external temperature (Fahrenheit)
4. Add time of daily low temperature.
5. Daily High External Barometer (inhg)
6. Time of above
7. Daily Low External Barometer (inhg)
8. Time of above
9. High windspeed for the day
10. Time of above

Thanks Stu.
Ok Todd, I'll get them into the next release.

Cheers,
Stu.

Hi Todd,
I've made the changes we talked about, I've also added a few extras.

I've got it on test at:
http://www.trixology.com/live_weather/custom_cgi/watch_weather.php

I'm currently sending the data every 5 seconds (sadly the weather is pretty quiet here at the moment). All hi/lo times are sent as local.

[Edit: I wanted to add the 3 hour baro delta, but sadly ran out of time - maybe I'll get it in later in the week. I'm also going to drop the seconds from the high/low times]

Cheers,
Stu.

Looking good! I had my page almost set to go but decided to blow it up and take a approach to it. Looking forward to incorporating this new data!

Thanks Todd.

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 20, 2012, 12:47:52 AM
Nice work Ken [tup] I've just been having a look around all the pages - very nice!

Unfortunately I can't send you a build just at the moment - the one I've just put on-line needs to soak test for 24 hours. If it's still running when I get home from work tomorrow, I'll send you a build then. I'm aiming the next public release at this weekend.

Cheers,
Stu.

Thanks Stu!

Glad you like the website features :)

I've now done the WeatherCat setup page (http://saratoga-weather.org/wxtemplates/setup-WCT.php ) using my setup as an example .. I'd appreciate any feedback on that page (I'm a MAC dabbler, so maybe I don't have the instructions quite understandable for MACmasters).
The companion Settings-weather.php instructions are at http://saratoga-weather.org/wxtemplates/Settings-weather-WCT.php

I've not yet packed up a WCT-plugin.zip for distribution, but will do that if the next WeatherCat beta release has the new tags working as expected.

Best regards,
Ken
Title: Looks nice . . . but . . . (Re: New AJAX/PHP template for WeatherCat)
Post by: elagache on March 20, 2012, 02:17:55 AM
Hi Ken and WeatherCat fans,

Great Job!!  [tup]

Could you drive a few miles North and straighten out my WC Storm Monitor AppleScript?  [lol]

See them in action (and the AJAX updates are working too) at
http://saratoga-weather.org/wxtemplates/Test/wxindex.php

I confess to have had my nose to the grinding stone and not checked out your work at all.  So I am very impressed at having finally looked at your handywork . . . . .

 ;) Just one thing . . . . . Your disclaimer at the bottom is a bit troubling:

Never base important decisions on this or any weather information obtained from the Internet.

Well, if we can't use anything we learn from the Internet to inform our decisions . . . . what should we use?  The Zambretti Forecaster (http://www.meteormetrics.com/zambretti.htm)!?!??  ;D

(http://www.alanwalker-barometers.com/Showroom/Aneroid_Barometers/5675_N%25Z_Forecaster/FC_1.jpg)

These days, flipping a coin is starting to look . . . . scientific!!  :o

Cheers, Edouard  [cheers1]
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Steve on March 20, 2012, 03:06:18 AM
I'd appreciate any feedback on that page

I've just perused the instructions quickly. I'm somewhat familiar with your instruction method, having fiddled with your WeatherSnoop template a bit. One note that needs changed is:

Quote
Note: WeatherCat is the successor software to LWC (Lighthouse Weather Center) software

Lighthouse should be Lightsoft (I've done the same thing on a few occasions.)

Steve
Title: Re: Looks nice . . . but . . . (Re: New AJAX/PHP template for WeatherCat)
Post by: saratogaWX on March 20, 2012, 06:05:52 AM
Hi Ken and WeatherCat fans,

Great Job!!  [tup]

Could you drive a few miles North and straighten out my WC Storm Monitor AppleScript?  [lol]

See them in action (and the AJAX updates are working too) at
http://saratoga-weather.org/wxtemplates/Test/wxindex.php

I confess to have had my nose to the grinding stone and not checked out your work at all.  So I am very impressed at having finally looked at your handywork . . . . .



Thanks for the kind words Edouard   [computer]  [biggrin]

Sadly, I have no experience with AppleScript to assist you .. JavaScript, PHP, HTML, CSS - yes.


;) Just one thing . . . . . Your disclaimer at the bottom is a bit troubling:

Never base important decisions on this or any weather information obtained from the Internet.

Well, if we can't use anything we learn from the Internet to inform our decisions . . . . what should we use?  The Zambretti Forecaster (http://www.meteormetrics.com/zambretti.htm)!?!??  ;D

These days, flipping a coin is starting to look . . . . scientific!!  :o

Cheers, Edouard  [cheers1]

Ah.. the disclaimer is on all the pages (in the footer.php) and even translated to all the languages supported by the template sets -- Just a reminder that the website operator has no liability for personal decisions based on the data displayed.  We amateurs have to rely on the National weather service to be the authority (and accept the blame for bad forecasts)  [rainyluck]

I'd appreciate any feedback on that page

I've just perused the instructions quickly. I'm somewhat familiar with your instruction method, having fiddled with your WeatherSnoop template a bit. One note that needs changed is:

Quote
Note: WeatherCat is the successor software to LWC (Lighthouse Weather Center) software

Lighthouse should be Lightsoft (I've done the same thing on a few occasions.)

Steve
Thanks Steve .. I've changed the page to use Lightsoft.  I also added a bit of info for folks who already have WeatherCat configured to upload their own template pages so their existing website can chug along while the required WCTtags.php page is added to their regular uploads.

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: WCDev on March 20, 2012, 04:54:12 PM
Looks fine to me Ken  [tup]

However, http://saratoga-weather.org/wxtemplates/Settings-weather-WCT.php returned a 404?

The build is still running so I'll be sending you a link to an interim download sometime over the next few hours.

Todd, I'm not sure I have your current email address? If you can send it to me, I'll get the link to you also.

Cheers,
Stu.
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on March 20, 2012, 05:23:11 PM
Looks fine to me Ken  [tup]

However, http://saratoga-weather.org/wxtemplates/Settings-weather-WCT.php returned a 404?

The build is still running so I'll be sending you a link to an interim download sometime over the next few hours.

Todd, I'm not sure I have your current email address? If you can send it to me, I'll get the link to you also.

Cheers,
Stu.

D'Oh .. manually typing URLs is a tricky business.. the corrected URL for the Settings-weather.php settings is:

http://saratoga-weather.org/wxtemplates/Settings-config-WCT.php

Thanks,

Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: nowait on July 07, 2012, 03:27:29 AM
Ken,

How do I add my custom graphs to the list of graphs to display?
Do I add the new graphic file names and variable names to the wxgraphs.php or to the wctags.php, ??

Thanks
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on July 07, 2012, 03:42:26 AM
Ken,

How do I add my custom graphs to the list of graphs to display?
Do I add the new graphic file names and variable names to the wxgraphs.php or to the wctags.php, ??

Thanks

For WeatherCat, you'll need to do both.

Add the custom tags to the WCTtags.php in your templates/ directory .. that will cause generation and upload of the graphic file then the $WX[] variable for the tag name will have the name of the graphic file created.

Then change wxgraphs.php in the WCT section to add your graphics using the stock graphics as examples.

Best regards,
Ken
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: nowait on July 08, 2012, 04:06:16 AM
Is there anything else that needs to be changed?  I'm trying to figure out how the scripts will know what the actual file names of the graphics to load.

Maybe I'm thinking too hard :)

My test page is http://nowaitweather.com/wxgraphs_new.php
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: saratogaWX on July 08, 2012, 05:37:38 AM
Well, you've got the correct (I think) stuff in WCTtags.php template
Code: [Select]
GRALLDIALS|GRALLDIALS$|// Weather Station Console Gauges:|:
GRCUSTOM1|GRCUSTOM1$|// Custom Graph 1:|:
GRCUSTOM2|GRCUSTOM2$|// Custom Graph 2:|:
GRCUSTOM3|GRCUSTOM3$|// Custom Graph 3:|:
GRCUSTOM4|GRCUSTOM4$|// Custom Graph 4:|:
GRCUSTOM5|GRCUSTOM5$|// Custom Graph 5:|:
GRCUSTOM6|GRCUSTOM6$|// Custom Graph 6:|:

It looks like WeatherCat is ignoring those items as they are not coming out parsed (and so no graph file is generated)
I'm guessing that you have to configure WeatherCat custom graphs in the software for them to be produced with those tag names  :-\
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: HairyMcLeary on July 08, 2012, 12:12:47 PM
I have this working here;

http://www.oamaruweather.net.nz/wxgraphs.php (http://www.oamaruweather.net.nz/wxgraphs.php)

This is what I have in my WCTtags.php

CUSGR4|CUSTOMGRAPH$4$|// Custom graph 4 :|:
CUSGR7|CUSTOMGRAPH$7$|// Custom graph 7 :|:
CUSGR8|CUSTOMGRAPH$8$|// Custom graph 8 :|:
CUSGR1|CUSTOMGRAPH$1$|// Custom graph 1 :|:

I think you have the incorrect tag for custom graphs, it should be CUSTOMGRAPH$N$  N=the custom graph number.

Tony
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: nowait on July 08, 2012, 02:24:13 PM
That was it.  Thanks!

Where do I find the official list of Tags at?  I have a couple more to add and I don't have them right either :)
Title: Re: New Saratoga AJAX/PHP template plugin for WeatherCat under construction...
Post by: Administrator on July 08, 2012, 04:28:58 PM
That was it.  Thanks!

Where do I find the official list of Tags at?  I have a couple more to add and I don't have them right either :)

All current tags are available live on-line so you can see how they look: http://live.trixology.com/custom/ (http://live.trixology.com/custom/)