Author Topic: Alternative-Dashboard Version 6.21  (Read 150934 times)

0 Members and 1 Guest are viewing this topic.

Offline jgillett

  • Forecaster
  • *****
  • Posts: 1187
  • Boltek, Win7 Pro, ToA
    • TiggrWeather Phoenix
Re: Alternative-Dashboard Version 6.21
« Reply #575 on: August 31, 2011, 03:15:10 AM »
It's up and running  \:D/ I don't know if it's me but the dashboard is JUST slightly wider than the spot it's sitting in.

From my viewpoint it fits perfectly within the window. There is no spillover.

However, you do have some validation errors to look at - nothing really major.
John
W7JKG

Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #576 on: August 31, 2011, 07:44:58 AM »
Looks great!  You're missing the very small raising, falling and steady arrow images though and you may want to go with transparrent gif images of the sun and moon so you don't get the background.   :grin:

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #577 on: August 31, 2011, 08:42:14 AM »
Thanks guys. I fixed the width issue but by 2:30 am I was done Lol. Hope to work on it more tonight. Scott where do I find the GIF's and what do I change to use them? The Ajaxwdwx.js ? I don't seem to be getting AQI updates? Is that an issue on their end or mine?

Thanks

** Arrows are fixed and working **
« Last Edit: August 31, 2011, 08:48:05 AM by Strgazr27 »
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #578 on: August 31, 2011, 07:05:09 PM »
Thanks guys. I fixed the width issue but by 2:30 am I was done Lol. Hope to work on it more tonight. Scott where do I find the GIF's and what do I change to use them? The Ajaxwdwx.js ? I don't seem to be getting AQI updates? Is that an issue on their end or mine?

Thanks

** Arrows are fixed and working **

Glad you found the images!  You still need to update the images for wind direction and current conditions in the main ajax-dashboard.php file too.  Make it match what you set them to in the java script.  They need to be set in both because the page loads and the java only updates.  The AQI is a separate module that you have to configure, have you done all that yet?

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #579 on: August 31, 2011, 07:18:02 PM »
Glad you found the images!  You still need to update the images for wind direction and current conditions in the main ajax-dashboard.php file too.  Make it match what you set them to in the java script.  They need to be set in both because the page loads and the java only updates.  The AQI is a separate module that you have to configure, have you done all that yet?

Scott


Scott I haven't configured the AQI so that is likely the issue. I'm hoping to work on the remaining images later after company leaves. Which images am I looking for? Do I use the GIF or JPG version? Thanks for the help on this. REALLY happy with the way it looks.
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #580 on: August 31, 2011, 09:07:38 PM »
Scott I haven't configured the AQI so that is likely the issue. I'm hoping to work on the remaining images later after company leaves. Which images am I looking for? Do I use the GIF or JPG version? Thanks for the help on this. REALLY happy with the way it looks.
Set the following line is AltAjaxDashboardConfig6.php to .png instead of .jpg
Code: [Select]
// optional settings for the Wind Rose graphic in ajaxwindiconwr as wrName . winddir . wrType
$wrName        = 'wr-';              // first part of the graphic filename (followed by winddir to complete it)
$wrType        = '.jpg';             // extension of the graphic filename
$wrCalm        = 'wr-calm.jpg';      // set to full name of graphic for calm display ('wr-calm.gif')
Then at the bottom of ajax-dashboard6.php, find the block of images that show .gif (like this snip)
Code: [Select]
// pick the NOAA style condition icon based on iconnumber
function newIcon($numb) {

  $iconList = array(
"skc.gif",          //  0 imagesunny.visible
"nskc.gif",         //  1 imageclearnight.visible
"bkn.gif",          //  2 imagecloudy.visible

And change all in that section only to .jpg instead of .gif.

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #581 on: August 31, 2011, 09:10:46 PM »
Scott I haven't configured the AQI so that is likely the issue. I'm hoping to work on the remaining images later after company leaves. Which images am I looking for? Do I use the GIF or JPG version? Thanks for the help on this. REALLY happy with the way it looks.
You are still missing the steady arrow (blue arrow pointing left).  It's in the archive along with other images you may need for Version 6.2x.  Put them all in the same directory as the other arrows.

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #582 on: September 01, 2011, 04:28:04 PM »
OK I THINK I have the arrow situation under control. Still need to fix a few other small issues but I have a question. How do I configure the AQI to pick up the values for NY? Do I configure it within the Get AQI script? What URL do I use to fetch the data?

Any help is appreciated.
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #583 on: September 01, 2011, 07:04:47 PM »
You want the value for NYC Bobby?

Here's the code. Save it as get-aqi-rss.php

Code: [Select]
<?php
//Current Air Quality URL
$urlRealtime "http://feeds.enviroflash.info/rss/realtime/94.xml";  //New York City, NY
// Images Directory
$imagesDir "./ajax-images";

// GET THE DATA FROM URL
getAQIdata($urlRealtime"realtime");


//// FUNCTIONS
// Data aquisition
function getAQIdata($AQIurl,$type) {
global $$type;

$$type = array();
$typeA $type;
$typeA = new DOMDocument();
$typeA->load($AQIurl);
foreach ($typeA->getElementsByTagName('item') as $node) {
$itemRSS = array ( 
'title' => $node->getElementsByTagName('title')->item(0)->nodeValue,
'desc' => $node->getElementsByTagName('description')->item(0)->nodeValue,
);
array_push($$type$itemRSS);
}
}


// strip out the needed data
preg_match('|<br /><br />\n(.*) - (.*) AQI - (.*)<br />\n|Uis'$realtime[0]["desc"], $r3);
$realIndex2 'N/A';
$realValue2 'N/A';
$realMeasure2 'N/A';

// search for two AQI types
if(preg_match('|<br /><br />\n(.*) - (.*) AQI - (.*)<br />(.*) - (.*) AQI - (.*)</div>|Uis'$realtime[0]["desc"])) {
   
preg_match('|<br /><br />\n(.*) - (.*) AQI - (.*)<br />(.*) - (.*) AQI - (.*)</div>|Uis'$realtime[0]["desc"], $r3);
   
$realIndex2 trim(strip_tags($r3[4]));
   
$realValue2 trim(strip_tags($r3[5]));
   
$realMeasure2 trim(strip_tags($r3[6]));
}

$realIndex1 trim(strip_tags($r3[1]));
$realValue1 trim(strip_tags($r3[2]));
$realMeasure1 trim(strip_tags($r3[3]));

// get the last update
preg_match('|Last Update: (.*)</i>|'$realtime[0]["desc"], $r4);
$realUpdate trim(strip_tags($r4[1]));

// arrays for comparing levels and values
$aqiValues = array('0-50''51-100''101-150''151-200''201-300''301-500');
$aqiLevels = array('Good''Moderate''Unhealthy for Sensitive Groups''Unhealthy''Very Unhealthy''Hazardous');
$aqiGraphic = array('AQI1.jpg''AQI2.jpg''AQI3.jpg''AQI4.jpg''AQI5.jpg''AQI6.jpg');  ////////////////////////////////////////////


// Associate AQI level with graphic icon
function getGraphic($value$levels$graphic$iDir) {
   global 
$levelImage;
   
   
$var array_search($value$levels);
   if(
$value !== 'N/A') {
   $levelImage "<img src=\"".$iDir."/".$graphic["$var"]."\" alt=\"".$levels["$var"]."\" title=\"".$levels["$var"]."\" border=\"0\" />";
   echo $levelImage;
   }
   else {
   $levelImage "<img src=\"".$iDir."/aqi_nodata_text.gif\" alt=\"No Data\" title=\"No Data\" border=\"0\" />";
   echo $levelImage;
   }
}

////  END OF FUNCTIONS

?>
Tony




Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #584 on: September 01, 2011, 08:14:41 PM »
Tony,

Thanks bud! You rock !
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline jahuff

  • Member
  • *
  • Posts: 46
    • johnsnhweather
Re: Alternative-Dashboard Version 6.21
« Reply #585 on: September 04, 2011, 08:35:14 PM »
Hi Everyone,

I am almost complete with the conversion to Ver. 3 of Ken's templates. I have a problem with getting the Alternative Dashboard working. I have the latest version of the Dashboard. The website is located at www.johnsnhweather.com. The problem can be seen at www.johnsnhweather.com/althome.php

If you look at the source for the page the code stops after the radar image. The code below is what follows but will not run.

Code: [Select]
<?php if(isset($SITE['ajaxDashboard']) and file_exists($SITE['ajaxDashboard']))
 { include_once("ajax-dashboard621.php");
   } else {
print "<p>&nbsp;</p>\n";
print "<p>&nbsp;</p>\n";
print "<p>Note: ajax-dashboard not included since weather station not yet specified.</p>\n";
        for (
$i=0;$i<5;$i++) { print "<p>&nbsp;</p>\n"; }
}?>


<div align="center">
<div id="elixirs1">
<?php include("record.php"); print $breakerreport?>
</div>
</div>
<br/>
  <table width="70%" style="border: none">
  <tr><td align="center">
    <img src="http://icons.wunderground.com/data/640x480/<?php echo $SITE['WUregion']; ?>_rd_anim.gif" alt="Regional Radar" width="310" height="240" style="margin: 0px; padding: 0px; border: none" />
  </td>
  <td align="center">
    <img src="http://icons.wunderground.com/data/640x480/<?php echo $SITE['WUregion']; ?>_ir_anim.gif" alt="Regional Infrared Satellite" 
      width="310" height="240" style="margin: 0px; padding: 0px; border: none" />
  </td>
  </tr>
  <tr><td colspan="2" align="center"><small>Radar/Satellite images courtesy of <a href="http://www.weatherunderground.com">Weather Underground</a>.</small></td></tr>
  </table>
    </div>
    <?php
############################################################################
include("wxscrollinfo2.php");
############################################################################
?>

<br/>

<?php
############################################################################
include("wxscrollinfo.php");
############################################################################
?>

<br/>
<?php
############################################################################
include("wxsnow.php");
############################################################################
?>

<?php
############################################################################
#include("wxtext.php");
############################################################################
?>

</div><!-- end center -->

</div><!-- end column-dark -->

</div><!-- end main-copy -->

<?php
############################################################################
include("footer.php");
############################################################################
# End of Page
############################################################################
?>

Thanks,

John
« Last Edit: September 04, 2011, 08:51:37 PM by jahuff »

Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #586 on: September 04, 2011, 09:15:13 PM »
Where's your ajax dashboard located John?

Should be here and it gives an error loading it

http://www.johnsnhweather.com/ajax-dashboard621.php
Tony




Offline jahuff

  • Member
  • *
  • Posts: 46
    • johnsnhweather
Re: Alternative-Dashboard Version 6.21
« Reply #587 on: September 04, 2011, 10:56:01 PM »
Hi Tony,

My dashboard is located at
http://www.johnsnhweather.com/ajax-dashboard621.php

I'm not sure why the error is comming up.

John

Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #588 on: September 05, 2011, 02:00:17 AM »
Thanks to Scott and Tony I have the new dash installed and have the watch box also up and running  \:D/

My question is though, How the HELL did I wind up with dual them switchers and how the hell do I fix it  ](*,)
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #589 on: September 05, 2011, 08:04:43 AM »
Hi Tony,

My dashboard is located at
http://www.johnsnhweather.com/ajax-dashboard621.php

I'm not sure why the error is comming up.

John

No go John

HTTP Error 500 (Internal Server Error): An unexpected condition was encountered while the server was attempting to fulfill the request.
Tony




Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #590 on: September 05, 2011, 08:18:58 AM »
Thanks to Scott and Tony I have the new dash installed and have the watch box also up and running  \:D/

My question is though, How the HELL did I wind up with dual them switchers and how the hell do I fix it  ](*,)

Not sure what you mean!  What is dual?

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #591 on: September 05, 2011, 08:21:23 AM »
Hi Tony,

My dashboard is located at
http://www.johnsnhweather.com/ajax-dashboard621.php

I'm not sure why the error is comming up.

John

John,

I'm seeing your page but it needs to be called from within the normal template, not shown on it's own.

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline jahuff

  • Member
  • *
  • Posts: 46
    • johnsnhweather
Re: Alternative-Dashboard Version 6.21
« Reply #592 on: September 05, 2011, 08:31:48 AM »
Hi All,

The problem was in my PHP code of Alternative-Dashboard Version 6.21, I had uncommented the last two functions langtransstr and langtrans with Ver 3 of Kens code they must be commented PHP doesn't allow duplicate defs for function names. Thanks for the fix Ken.

Thanks,
John

Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #593 on: September 05, 2011, 08:40:56 AM »
Thanks to Scott and Tony I have the new dash installed and have the watch box also up and running  \:D/

My question is though, How the HELL did I wind up with dual them switchers and how the hell do I fix it  ](*,)

Not sure what you mean!  What is dual?

Scott

There are 2 style switchers in the menubar. Took me a bit to see that  #-o
Tony




Offline BurnsvilleWeather

  • Burnsville, MN USA
  • Forecaster
  • *****
  • Posts: 863
  • Retired from Weather!
Re: Alternative-Dashboard Version 6.21
« Reply #594 on: September 05, 2011, 08:50:08 AM »
The problem was in my PHP code of Alternative-Dashboard Version 6.21, I had uncommented the last two functions langtransstr and langtrans with Ver 3 of Kens code they must be commented PHP doesn't allow duplicate defs for function names. Thanks for the fix Ken.

Yup, that would do it!  I put that in at the bottom (commented out) for backwards compatability!  Glad Ken got you going, he's VERY good at this stuff!

Scott
www.BurnsvilleWeatherLIVE.com (Formally Webster Weather LIVE)
Home of the Alternative Dashboard and Mobile Dashboard Scripts. Weather Display Scripts and Graphics


Davis VP2 with, UV, Solar, Leaf, Web Cam.

Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #595 on: September 05, 2011, 09:08:49 AM »
Quote
There are 2 style switchers in the menubar. Took me a bit to see that  #-o

Yep and I CANNOT figure out why ? :?: ](*,)
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #596 on: September 05, 2011, 09:20:01 AM »
check in menubar.php and look for 2 references to the color theme switcher Bobby

<!-- begin Color Theme Switcher Plugin http://www.642weather.com/weather/scripts.php -->
<!-- end Color Theme Switcher Plugin http://www.642weather.com/weather/scripts.php -->

Must be in your menubar twice
Tony




Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #597 on: September 05, 2011, 09:32:15 AM »
check in menubar.php and look for 2 references to the color theme switcher Bobby

<!-- begin Color Theme Switcher Plugin http://www.642weather.com/weather/scripts.php -->
<!-- end Color Theme Switcher Plugin http://www.642weather.com/weather/scripts.php -->

Must be in your menubar twice

Fixed !! I didn't think to check Menubar.php as I don't recall putting it there again.

You keep this up Tony I'm gonna owe you a case of beer !

Thanks bud!
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



Offline CNYWeather

  • Forecaster
  • *****
  • Posts: 2296
    • CNYWeather
Re: Alternative-Dashboard Version 6.21
« Reply #598 on: September 05, 2011, 09:43:25 AM »
Budweiser please lol  :-P

See your SWSP Alert is working. Can I make a suggestion?

Clicking your alerts brings you to a national page. I'd change this in SWSP-config.php:

$alertDetailPage = 'wxalertslocal.php';  // web page for displaying map & details

Create yourself a local page, then local visitors will get those local alerts right off the bat

Code: [Select]
<?php
############################################################################
# A Project of TNET Services, Inc. and Saratoga-Weather.org (WD-USA template set)
############################################################################
#
#   Project:    Sample Included Website Design
#   Module:     sample.php
#   Purpose:    Sample Page
#   Authors:    Kevin W. Reed <kreed@tnet.com>
#               TNET Services, Inc.
#
Copyright: (c) 1992-2007 Copyright TNET Services, Inc.
############################################################################
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA
############################################################################
# This document uses Tab 4 Settings
############################################################################
require_once("Settings.php");
require_once(
"common.php");
############################################################################
$TITLE$SITE['organ'] . " - Local Weather Alerts";
$showGizmo true;  // set to false to exclude the gizmo
include("top.php");
############################################################################
?>

<link rel="stylesheet" type="text/css" href="SWSPalerts.css" media="screen" title="screen" />
</head>
<body>
<?php
############################################################################
include("header.php");
############################################################################
include("menubar.php");
############################################################################
?>


<div id="main-copy">
<h1>Local Weather Alerts</h1>
    <div id="subheader">
        <h3>Click on the map or scroll for your weather office</h3>
<?php include("SWSPloc-inc.php"); ?>

</body>
</html>

</body>

</html><!-- end main-copy -->

<?php
############################################################################
include("footer.php");
############################################################################
# End of Page
############################################################################
?>

Last thing, you have SWSPalerts.css uploaded too? That will change the look of the alerts on the main page.
Tony




Offline Strgazr27

  • "The Cam Man"
  • Forecaster
  • *****
  • Posts: 590
    • Kings Park Weather
Re: Alternative-Dashboard Version 6.21
« Reply #599 on: September 05, 2011, 11:13:22 AM »
Think I got it now :)
Bobby M.
Davis VP2 6152 w Daylight FARS - Logitech C525 and C310
WD - WDLive - GRLevel3 - Image Salsa - VVP - Startwatch

"http://www.kingsparkweather.com"
KNYKINGS7 on WU



 

anything