Alternative ajaxWDwx.js Script v 9.14

I take yours as a starting point. What I should do with this file? Should I rename to ajaxWDwx-settings.js and customize it?

Thanks

Looks OK except you need to change your source for the FWI to this line in ajaxWDwx-settings.js:

fireImg.src = imgDir+“Fire#IMGNR#.png”;

BTW: Edit your profile and add a link to your website please.

Done!

Fire image still doesn’t work as sun icon. I uploaded serveral folders in fire folder like 1, 2, 3, … but link seems to point to /ajax-images/fire0.gif instead of /ajax-images/fire/7/…

Thanks Rainer!

Aha, you want the FWI icons in: “./ajax-images/fire/7/fire-3.jpg
For that you need:
fireImg.src = imgDir+“fire/7/fire-#IMGNR#.jpg”;

If you have placed your SUN in a different folder then that needs to be changed in “ajax-dashboard.php”.

Hi
I have this great script working well now, I would just like to get the Metric/English Choice in the top of the dashboard as in your example, however I am using the “alternative Dashboard” and I can’t see the “Table Top section” in it. I did post a text copy of my ajax dashboard in my post earlier in this thread ( 13 jan ). I do now have the conversion link above the table, but think it would look neater your way. Any help appreciated.
Phil

I think Scott can help you with that one.

mmm, still doesn’t work. Fire image seems to be established in ajax-dashboard.php amb settings in ajaxWDwx-settings.js seems to be to take no efect.
For moon phase image it’s the same, settings seems to be placed in ajax-dashboard.php and I don’t know how to change to match imgDir+“moon/#BG#/#NS#-moon#AGE#.gif”;

Thank you!

NEW RELEASE v9.08

Version 9.08 - 17-Jan-2010Fixed ...... problem with dates when timeformat is set to 12h clock (AM/PM) in WDisplay.

The problem with the dates showing AM when it’s PM has been fixed.
This happened when the time format in WDisplay was selected as “12 hour clock”.
This resulted in WDisplay reporting times in the clientraw.txt file as eg. 03:17PM instead of my expected format of 15:17

Download is available on the [color=blue]front page[/color].

For the Moon Phase you need to set the corresponding “ajaxTags” in your “ajax-dashboard.php” … see [color=blue]page 1, post #2[/color] for the tags.

You can’t use FWI as you’ve got Scots Chandler Burning Index algo in your ajax-dashboard.php.
I will have to make provision for this … added to TODO list.

For the sun image you’re using, it’s best you go back to the old one as mine is intended for the Almanac background to show sunrise/sunset times.

The problem with the dates showing AM when it's PM has been fixed.

Hmmm…upgraded to 9.08 and currently it is @12:15pm but my ajax update shows

Updated: @ 01/17/2010 0:15:58 pm - updated 0 sec ago

Jack

Aha, I get it:
`
ISO EURO USA TIME


09:15 09:15 09:15 am
12:15 12:15 12:15 pm <— You don’t want this time to be 00:15 pm for English UOM?
13:15 13:15 01:15 pm
00:15 00:15 00:15 am <— Is this correct for English UOM or do you want it to be 12:15 am?


`
Will have to fix this one as well I think … i.e. when it’s 00:01 pm then change to 12:01 pm

Will have to fix this one as well I think ... i.e. when it's 00:01 pm then change to 12:01 pm

yes that’s it…thanks, no hurry it only happens one hour a day and only people like me notice…LOL!

Jack

NEW RELEASE v9.09

Version 9.09 - 17-Jan-2010Fixed ...... problem with JS Date function showing [color=red]00:15pm[/color] instead of [color=green]12:15pm[/color]

The javascript date prototype was fixed to show 12:00am instead of 00:00am, and 12:00pm instead of 00:00pm

Download is available on the [color=blue]front page[/color].

[quote]
It includes the date … you need to put the temperature in it’s own span i.e.
[color=brown]89.6

The problem, after troubleshooting, is the Google map/radar script. It has temporarily been disabled and now the page works and switches fine now (this being a Firefox issue). Feel free to now check and let m know if you notice any further problems. http://www.k3jae.com/wxindex-test.php

You’ll have to consult your testtags.php file for that.

That is the problem… I see no tags where the station warmest/coldest day/night is seperated out. May have to speak with Brian on that… So for now that will need to remain as is.

No need to ask Brian.
Here’s what you can do assuming the tag in question is:
$mwarmestdayonrecord = ‘25.4°C on: 01 Jan 2010’;

Then you do this:`[color=brown]

<?php list($temp, $on, $day, $month, $year) = split("[- ]+", $mwarmestdayonrecord); $mthNames = array('Jan'=>"1",'Feb'=>2,'Mar'=>3,'Apr'=>4,'May'=>5,'Jun'=>6 ,'Jul'=>7,'Aug'=>8,'Sep'=>9,'Oct'=>10,'Nov'=>11,'Dec'=>12); $date = mktime(0,0,0,$mthNames[$month],$day,$year); $wdDate = date($SITE['dateOnlyFormat'],$date); ?>

[/color]`

And then put this in your HTML output:`[color=brown]

<?php echo $temp; ?> on: <?php echo $wdDate; ?>  [/color]`

PS: Download the latest release from the front page and install on your server (only the ajaxWDwx.js).
You’re getting a javascript error which I’ve fixed.

Modified: Code above had errors and was updated accordingly

TODO LIST / DEVELOPMENT IN PROGRESS

  1. Tag for WDLive “Input Daily WeatherWeather Warning Forecast Input” and/or “Davis VP Forecast/Warning Text” (alerts).
  2. Tag for Radar picture with frequent update (minutes settable).
  3. Tag for Chandler Burning Index.
  4. Tag for Tide image/graph.
  5. Tag for Sun Position image/graph.
  6. Tag for Sun Path image/graph.
  7. Tag for Wind Direction Plot Graph.
  8. Tag for any kind of imaginable image or graph with optional update frequency.
  9. Class tags for converting time/date between US/EURO formats when switching UOM (convTime & convDate).
  10. Prevent script from starting unless settings have been loaded.
  11. Load “ajaxWDws-settings.js” dynamically from within script in case it’s not declared in “top.php”.
  12. Simplyfy adding of new “ajaxTags” by setting them up in a “tagList” array to be loaded during initialization.

This list is also contained on the front page.

OK, this was done, but before updating the live site I was wondering when doing this how does this code work for the others I need. Allow me to explain:

I need the following: $warmestnightonrecord $warmestdayonrecord $coldestnightonrecord $coldestdayonrecord
So duplicating your code and changing the tag name is fine… but the HTML code is simply a repeat of what you offered. Giving me the exact same data four times. I do not see a final conversion “output” tag. ie. $varcoldestday= etc. Am I thinking this through correctly? I apologize for my ignorance here but PHP is a weak area for me and trying to understand.

PS: Download the latest release from the front page and install on your server (only the ajaxWDwx.js). You're getting a javascript error which I've fixed.

Modified: Code above had errors and was updated accordingly

Did update to 9.09 and system locked up… broke it. No updates, and could not switch to the Metric side. So reverted back to older ajaxWDwx.js. I only updated that file, Am I needing to update the others as well as I understood by your comment only the ajaxWDwx.js file would need to be updated.