Author Topic: Weather Template and scripts from Leuven/Belgium/Europe  (Read 195200 times)

0 Members and 1 Guest are viewing this topic.

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #375 on: September 21, 2014, 11:37:00 AM »
I have been adding new pages mostly in an iFrame - the problem I am having is that I would like the iFrame to be solid so that the background image does not mask what is in the frame. 
For instance my school closure page - http://rathdrumweather.us/weather2/index.php?p=401&wp=MB is hard to read.  I could change the background but just want the frame easy to read.  Also if I use a solid color such as pastel the bottom half of the page is brown, I guess something in the CSS. 

Thanks - Dennis
Hello Denis,
No CSS but a missing </div>
You can see also that the footer is located under the main part of the page NEXT to the side-area with the menu. It should be below the side-area.

There is a wsNewPage.php in the weather2/inc/ folder you could use as a starting point and it is in the menu system at:
http://rathdrumweather.us/weather2/index.php?p=900&wp=MB
You could use that script as a starting point (after making a copy).

As I can not inspect your script (it is PHP) could you please send me a zipped version?

Wim

Offline KK7X

  • Contributor
  • ***
  • Posts: 128
  • KIDRATHD3
    • Rathdrum Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #376 on: September 21, 2014, 11:44:53 AM »
Thanks Wim - the new page template is what I am using.  I will send you the script. 

Dennis

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #377 on: September 21, 2014, 11:51:27 AM »
Thanks Wim - the new page template is what I am using.  I will send you the script. 

Dennis
For the next pages you are developing, use this 2.6 version of wsNewPage.php
Then I can look into the php code also.
Wim


Offline KK7X

  • Contributor
  • ***
  • Posts: 128
  • KIDRATHD3
    • Rathdrum Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #378 on: September 21, 2014, 11:54:48 AM »
Will do - thanks  =D&gt;

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #379 on: September 21, 2014, 12:30:26 PM »
Wim,
I don't know if you can or not,  but Ken True has a few lines so a script can be Viewed by anyone using the "?sce=view" on each page. I'll look it up and forward it to you
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #380 on: September 21, 2014, 01:03:38 PM »
Wim,
I don't know if you can or not,  but Ken True has a few lines so a script can be Viewed by anyone using the "?sce=view" on each page. I'll look it up and forward it to you
Thanks, but nearly all scripts in v2.6 have those lines. Only the settings /key files are excluded.  I need it to give better support. Wim

Offline KK7X

  • Contributor
  • ***
  • Posts: 128
  • KIDRATHD3
    • Rathdrum Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #381 on: October 02, 2014, 11:24:51 AM »
I have the template working pretty well to my satisfaction.  Only issue is with the Local Radar under Precipitation Radars - WU Radar Station OTX always shows Radar Down for Maintenance.
I know that KOTX (OTX) is working as I also use  GRLevel3

http://rathdrumweather.us/weather2

Dennis

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #382 on: October 02, 2014, 03:10:07 PM »
I have the template working pretty well to my satisfaction.  Only issue is with the Local Radar under Precipitation Radars - WU Radar Station OTX always shows Radar Down for Maintenance.
I know that KOTX (OTX) is working as I also use  GRLevel3

http://rathdrumweather.us/weather2

Dennis
In general: go to http://www.wunderground.com/weather-radar/united-states/ and try to find your area. Right-click on the correct radar image and open the image in a new tab. You can then copy the string for that radar to the script.  As there are different sources for the radars there are also different strings.

I did find the string for OTX and put it in the script.
1. make a copy of weather2/inc/rain3Sources.php
2. unzip the attachment
3. replace the current script with the new one
4. check the settings in the script for the first radar.

Succes, Wim

Offline KK7X

  • Contributor
  • ***
  • Posts: 128
  • KIDRATHD3
    • Rathdrum Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #383 on: October 02, 2014, 03:11:34 PM »
Thanks once again Wim

Offline PeT

  • Member
  • *
  • Posts: 5
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #384 on: October 10, 2014, 03:53:08 AM »
I am trying to use config program for meteohub mhConfig.php but I get Internal Server Error (http://saajuu.net/weather2/). What could be the reason?

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #385 on: October 10, 2014, 04:12:25 AM »
I am trying to use config program for meteohub mhConfig.php but I get Internal Server Error (http://saajuu.net/weather2/). What could be the reason?
500 Internal Server Error  => google => lot of possibillities.
But the permissins settings are always the cause.

Some webhosting companies NEED 777  some other do NOT ALLOW 777.

So try 755 for the folder and it contents.
If still the error: try 755 for the folder and 644 for the contents.

===
http://saajuu.net/weather2/startHere.php  works OK so it is not a general problem.
===
The gauges folder is missing (or not the correct permission) an essential javascript.
Therefor the header is not containing the gauges.
Referenced in weather2/gauges/gaugeframe.php
<script src="./scripts/ddimgtooltip.min.js"></script>
It should be in the download. So maybe an upload error when installing?

Succes, Wim


Offline PeT

  • Member
  • *
  • Posts: 5
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #386 on: October 15, 2014, 08:02:03 AM »
New  installation / 755 for the folder and 644 for the contents and now it is working.

Now I am trying to use WMR200/Meteohub/Rasbperry. I do not understand why the weather station is offline. UploadMH / client.. files are updated and there is also meteohub-upload.test file.

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #387 on: October 15, 2014, 08:19:34 AM »
New  installation / 755 for the folder and 644 for the contents and now it is working.

Now I am trying to use WMR200/Meteohub/Rasbperry. I do not understand why the weather station is offline.
This message simply means as with all gauges that the realtime data is not current.
Consult the WikI http://wiki.leuven-template.eu/doku.php?id=uploadmh where is written that the file realtimeTags.txt is used for the gauges.
But http://saajuu.net/weather2/uploadMH/realtimeTags.txt is the original one with date/time form 22 september.
Quote
UploadMH / client.. files are updated and there is also meteohub-upload.test file.
It seems  indeed you are uploading clientraw files for use with WD-Live http://saajuu.net/weather2/uploadMH/clientraw.txt  but they  look a little empty to me. And you do not have WD-live enabled so I can not test it.

Your status page http://saajuu.net/weather2/index.php?p=83&lang=en  shows all data files in http://saajuu.net/weather2/uploadMH are not yet uploaded. Only the files from the download are there.

Did you already instructed Meteohub to upload the neede file by following the WiKi ?
http://wiki.leuven-template.eu/doku.php?id=uploadmh4

Succes, Wim
« Last Edit: October 15, 2014, 08:41:52 AM by wvdkuil »

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #388 on: October 22, 2014, 11:35:44 PM »
Wim,


I have been trying to add a badge to the menu showing updated pages and new pages.
The "New" or "Update" badges would look like the attached menu image from another site.
I have adjusted the wsMenuData.xml file to the following:



   <item    nr      = "52-1"
                show    = "wuPage"
                caption = "WU forecast"
           link    = "wuforecast/startLeuven.php"
           css     = "wuforecast/wuforecast.css"
           img="/img/update_icon.gif" align="right"
        />


I attempted to use   
Code: [Select]
img src="/img/update_icon.gif" align="right" and ended up with errors.
I am intending to use the same image on the main dropdown to show that there is an updated page within that dropdown.


Can you point me in the right direction to show the badges? I'm missing something and not sure what it is.  ](*,)


Regards,


Jonny J
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline wvdkuil

  • Wim van der kuil
  • Forecaster
  • *****
  • Posts: 1986
    • My PWS at Leuven Belgium Europe
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #389 on: October 23, 2014, 04:54:32 AM »
Wim,


I have been trying to add a badge to the menu showing updated pages and new pages.
The "New" or "Update" badges would look like the attached menu image from another site.
I have adjusted the wsMenuData.xml file to the following:



   <item    nr      = "52-1"
                show    = "wuPage"
                caption = "WU forecast"
           link    = "wuforecast/startLeuven.php"
           css     = "wuforecast/wuforecast.css"
           img="/img/update_icon.gif" align="right"
        />


I attempted to use   
Code: [Select]
img src="/img/update_icon.gif" align="right" and ended up with errors.
I am intending to use the same image on the main dropdown to show that there is an updated page within that dropdown.


Can you point me in the right direction to show the badges? I'm missing something and not sure what it is.  ](*,)


Regards,


Jonny J
Good morning Jonny J,

This is a totally new request, for me at least. There was no code for this in the current scripts.

Attached the folder with:
2 images, they go to weather2/img/ folder (in your case the quadcities/img/ folder)
2 replacements for the menu CSS, probably you have to reload the page to reload the css
1 replacement script:   weather2/wsMenuLoad.php
1 example for changes to the menu xml.
 
Please make a backup of the CSS and script before uploading the new ones.

In your changes above there are two xml entries. The image name and the alignment.
I implemented for now only the img part. The image is always at the right of the menu name.

You can specify two "shorthand" image-specifications, these use default images:
  img  = "new"
or
  img  = "updated"

You can also use your own image by setting the full path to an image, relative to the weather2/ folder
  img  = "img/menu_updated.gif"

Succes, Wim

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #390 on: October 23, 2014, 05:38:46 AM »
Wim,
I very much appreciate the hard work. I was not expecting results already, let alone re-working the files. I wasn't expecting them to be as complex. I was hoping it was alot simpler. As usual you come through!
Thanks for your hard work!
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #391 on: October 23, 2014, 07:10:47 PM »
Wim,
I put the gif images in the /img folder. The files come back with a 404 (not found) error. If I go and open the images individually via the website, the images appear. But on the menu they are missing with a spot showing where the icon is.
I have adjusted the permissions, with no change. I went into the wsMenuLoad.php file and made sure the link was OK, then followed the xml file you included. The images still don't appear.
I used the 'inspect element' in Google Chrome  and the gif images show as html files, not gif images.


Update: I got the images working. I went into the wsMenuLoad.php and changed the following:


Code: [Select]
if (isset($menuItem['img']) ){
        $img    = trim((string) $menuItem['img']);
        if ($img  == "updated") {$img= 'img/menu_updated.gif';}
        elseif ($img  == "new") {$img= 'img/menu_new.gif;}
        $img = ' <img src ="'.$img.'" alt ="">';

to:


Code: [Select]
if (isset($menuItem['img']) ){
        $img    = trim((string) $menuItem['img']);
        if ($img  == "updated") {$img= "img/menu_updated.gif";}
        elseif ($img  == "new") {$img= "img/menu_new.gif";}
        $img = ' <img src ="'.$img.'" align="right">';


Note the images now quoted. Now they are working. I also added "align = right" in. that way the images come up on the right side of the links.
Thanks again for setting this up. Much appreciated.
« Last Edit: October 24, 2014, 06:58:28 AM by jonnyj771 »
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline weatherbee

  • Senior Contributor
  • ****
  • Posts: 210
    • Sherman Ct. Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #392 on: November 07, 2014, 07:53:36 PM »
Wim,
This evening I got this error which has shut down the site:
Quote
Warning: SimpleXMLElement::__construct(): Entity: line 1: parser error : Space required after the Public Identifier in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): ^ in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): Entity: line 1: parser error : SystemLiteral " or ' expected in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): ^ in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): Entity: line 1: parser error : SYSTEM or PUBLIC, the URI is missing in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Warning: SimpleXMLElement::__construct(): ^ in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

Fatal error: Uncaught exception 'Exception' with message 'String could not be parsed as XML' in /home/shermqdj/public_html/weather3/wsMetarXml.php:87 Stack trace: #0 /home/shermqdj/public_html/weather3/wsMetarXml.php(87): SimpleXMLElement->__construct('<!DOCTYPE HTML ...') #1 /home/shermqdj/public_html/weather3/wsDataGet.php(147): include_once('/home/shermqdj/...') #2 /home/shermqdj/public_html/weather3/index.php(258): include_once('/home/shermqdj/...') #3 {main} thrown in /home/shermqdj/public_html/weather3/wsMetarXml.php on line 87

I'm not sure what is wrong.  Never got this before and didn't change anything.
Tom

EDIT:
I did find this:
Quote
Experimental ADDS is Down for Maintenance
Friday, Nov. 7th 3:00 pm MST
to
Monday, Nov. 10th 12:00 pm MST

Is there a way to get my site back running?
« Last Edit: November 07, 2014, 08:00:32 PM by weatherbee »

Offline KK7X

  • Contributor
  • ***
  • Posts: 128
  • KIDRATHD3
    • Rathdrum Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #393 on: November 07, 2014, 08:09:32 PM »
I am seeing the same error on my site. http://rathdrumweather .us/weather2

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #394 on: November 07, 2014, 09:05:32 PM »
I'm getting the same error. It's the Metarxml.php causing the error.
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #395 on: November 07, 2014, 09:06:08 PM »
Showing the URI is missing
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline ed2kayak

  • Ed
  • Forecaster
  • *****
  • Posts: 613
  • Davis Vantage Pro2 w/12 hr FARS, solar/uv
    • Cumberland Valley Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #396 on: November 07, 2014, 09:55:27 PM »
I commented out the lines that had errors, as a temporary fix.
Make a backup of file first, just try one change to see how it goes.


weatherbee- yes ADDS is down for maintenance. I think there is a back server, http://aviationweather.gov/dataserver. Will wait for Wim to check
« Last Edit: November 07, 2014, 10:00:45 PM by ed2kayak »
Ed
CoCoRaHS PA-CD-6,  Weather Underground KPAMECHA7, CWOP DW5425

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #397 on: November 07, 2014, 10:04:56 PM »
Kind of hard when you have a page that looks like this image I have attached
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)

Offline weatherbee

  • Senior Contributor
  • ****
  • Posts: 210
    • Sherman Ct. Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #398 on: November 07, 2014, 10:22:44 PM »
For now comment out line 87 and the site will work again.

Offline jonnyj771

  • Senior Contributor
  • ****
  • Posts: 220
    • Lightning Weather
Re: Weather Template and scripts form Leuven/Belgium/Europe
« Reply #399 on: November 07, 2014, 10:52:53 PM »
For now comment out line 87 and the site will work again.

I had to comment out lines 94 through 101 to get working again
Facebook:
Lightning Weather
   www.facebook.com/lightningweather
                             /groups/lightningweather
Lightning Weather Quad Cities
                             /lightningwxqc
                             /groups/lightningWXQC
Weather Station Hardware: Davis Vantage Pro2 6152
Weather Station Software: WD - 10.37S Build XXX (Beta)
Page Template: MeteoTemplate v1x. (Current Active)