All,
I wanted to display a few things that can be done with this script. I’ve set up some temporary zones that currently have some advisories.
Check out the top warning box here (the icons give it a nice touch):
http://www.relayweather.com/
Check out the summary page which allows you to view all zones you have entered in the script:
http://www.relayweather.com/AtomSummary.php
Check out the detail of each zone:
http://www.relayweather.com/AtomZone.php?zone=AZZ002&loc=Lake Havasu, Fort Mohave Arizona#WL
This is very easy to get going, supports the new NWS ATOM format and looks very nice. Thanks to Curly for a great job!!
Michael
curly
18 July 2009 13:39
4
Thanks Mike & Michael!
Made the change to $_GET in the AtomZone.php file.
Also changed the AtomFeed.php file putenv for the time zone to date_default_timezone_set.
I see another issue.
on this page, you have URL links with spaces. They should be urlencoded so the spaces are changed to %20, or a plus (+)
http://www.weather.ricksturf.com/AtomDemo.php
http://us3.php.net/urlencode
Im getting an error:
Warning: include(AtomArray.php) [function.include]: failed to open stream: No such file or directory
I didn’t see the (AtomArray.php) included in the zip file
Try running the AtomFeed.php file manually, you will then see three (3) files get created. AtomWork.php, AtomCache.php and AtomArray.php.
These three files are the files that are created and updated when you run the script AtomFeed.php
mth
18 July 2009 17:16
11
Hang tight…I’m sure Curly will have this resolved very shortly.
Mark, your server does not have permission to create files.
I logged in and CHMOD your “web” folder to 777, ran AtomFeed.php and it created the files, then I CHMOD the “web” folder back to 715.
Working fine here Thanks :lol:
Mark, your server does not have permission to create files.
I logged in and CHMOD your “web” folder to 777, ran AtomFeed.php and it created the files, then I CHMOD the “web” folder back to 715.
#-o LOL…Thanks again Mike. I see its working.
curly
18 July 2009 17:26
15
OK Back again…
Fixed the blank spaces in the URL.
Instead of downloading the zip file, copy the code here http://www.weather.ricksturf.com/scripts/AtomFeed.php?sce=view
As a side note, if you have a problem with the script or web page, please post a link.
Thanks
Curly
Mark - If you view the page source of the AtomFeed.php file, it will show errors if any. I didn’t see any.
I do show the program working - North Bend - Zone Advisories
If you want me to check the script for problems, please post a link for the AtomFeed.php file.
Thanks
Curly
Mike went in and changed my permissions and that fixed it. Thanks.
Great script! Thanks. I’m a little confused after reading the docs as what I have to do to get the the warning box part to work so that it has the icon next to it. I know I need to include AtomsFeed.php but I’m not sure of where I need to place some other code (tags). Can someone provide me the exact code I need and where it needs to be placed and in what file.
Thanks,
John
mth
18 July 2009 17:35
19
In your index.php, place this at the top just under your
<?php print $alert_box; ?>
Be sure you have called the AtomArray.php file too
Michael
Okay got the short term forecast to show. The warning box is not showing around. How do I get this to show and text centered?
Thanks,
John
mth
18 July 2009 17:47
21
This is controlled by your css file.
If you have $use_CLcss set to “true”, then the “advisoryBox” is used in your CSS file. I see that yours is commented out by the //. I would check there first for the formatting and uncomment.
curly
18 July 2009 17:52
22
John,
Your CSS file doesn’t have “advisoryBox” and that is what the script uses. There are two alternatives.
Find this
$alert_bocks = '<div class="advisoryBox">' . $alert_bocks . '</div>';
and change “advisoryBox” to “advisorybox” or “advisorybox1” or “advisoryBox2”
or you can use a defaulted box if you change $use_CLcss = true; to false.