[PHP] Fetching Local Weather
Hey Coders, I know there's a couple premade scripts to grab weather on hotscripts.com. I wanted to know if anyone has a simple method to fetch the day's local weather from something like yahoo. All I really need is the temperature, condition (rainy, sunny)and maybe windspeed. If I could include the icon for the condition that would be good too. Anyone have a simple solution for this that I can dump into my code? Thanks.
RE: [PHP] Fetching Local Weather
try http://www.gimpster.com/php/phpweather/index.php it's not simple solution though... Maciek -Original Message- From: JB [mailto:[EMAIL PROTECTED]] Sent: Friday, February 09, 2001 10:50 PM To: [EMAIL PROTECTED] Subject: [PHP] Fetching Local Weather Hey Coders, I know there's a couple premade scripts to grab weather on hotscripts.com. I wanted to know if anyone has a simple method to fetch the day's local weather from something like yahoo. All I really need is the temperature, condition (rainy, sunny)and maybe windspeed. If I could include the icon for the condition that would be good too. Anyone have a simple solution for this that I can dump into my code? Thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Fetching Local Weather
- Original Message - From: "JB" [EMAIL PROTECTED] Hey Coders, I know there's a couple premade scripts to grab weather on hotscripts.com. I wanted to know if anyone has a simple method to fetch the day's local weather from something like yahoo. All I really need is the temperature, condition (rainy, sunny)and maybe windspeed. If I could include the icon for the condition that would be good too. Anyone have a simple solution for this that I can dump into my code? Thanks. Using combinations of: $string=implode(file("http address"), ""); $array=explode("some starter tag", $string); $array=explode("some end tag", $array[1]); $endString=$array[0]; With the odd ereg_replace() to tweak the data you can grab info from wherever you want. However, you should get permission from the site, since this would count as a hit/page view on their site. Anna -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]