Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




Getting Weather From Bbc.co.uk



Hey guys I rarely speak on the forums lol so Im a bad member although i did take part in the giant picture chain thread! anywys I would like to implement a search feature i.e. a postcode box where a user inserts there postcode clicks a submit button then is sent to the corrosponding page on the bbc! the search box is on the bottom right hand side of the www.bbc.co.uk/weather a view source will tell you what you need to know I belive this is the code but you can go to the site to see more.
Code:
<td bgcolor="#99cc66" valign="top" colspan="3" rowspan="3" class="searchbox"><div style="padding:0px; margin:4px;" class="display"> <form name="search" method="get" action="/cgi-perl/weather/search/new_search.pl"><h2 style="padding:0px; margin:0px; color:#ffffff;"><label for="search_query">Search</label></h2><strong style="color:#ffffff;">for a new 5 day forecast</strong><br /> <div style="padding:0px; margin:0px; float:right;"><input type="image" value="Submit" src="/weather/images/gui/gr_but_submit_5day.gif" width="26" height="21" id="submit" name="submit" alt="GO" border="0" tabindex="3" /></div><input type="text" name="search_query" id="search_query" size="8" title="To search for a five day forecast please enter your location name or postcode and click GO" style="width:125px;" accesskey="8" tabindex="2" /> <br clear="all" /></form>
I'm learning snippets of flash all the time and working this out would really aid in understanding more of how flash handles things! I have an input box and button allready setup I just need to work out what code to insert in the on (release) { } section and what var's to call the input box and if anything else is need to process this I assume what they insert in input box on the bbc gets sent using the get command to a search then return something I can use .I want the user to open the bbc.co.uk page corresponding to the postcode seperatley (_blank) Many thanks if any Kirupians can point me in the right direction and explain along the way! cheers!Adam



KirupaForum > Flash > Flash 8 (and earlier)
Posted on: 04-22-2007, 07:31 PM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Weather.com
Hello all.

I am trying to incorporate the code from Weather.com into Flash MX. I was able to do it with google but this one is stumping me. Basically, it's an input text box that allows you to enter your city and submit it to see the weather forcast.

The Basic code in HTML (this is a trimmed down version of what weather.com gives you.) I will not be using their submit button.

I have used ( instead of < so you can see the code.

----------------------
(form method="post" action="http://www.weather.com/cgi-bin/uncgi/zip_city_search.cgi?par=internal&code=617416&site= logo&promo=english")

(input name="destination" type="text" size="8" value="")

(input type="image" src="http://image.weather.com/pics/button_go.gif" )

----------------------
Below is the CODE IN USE
----------------------
<form method="post" action="http://www.weather.com/cgi-bin/uncgi/zip_city_search.cgi?par=internal&code=617416&site= logo&promo=english">

<input name="destination" type="text" size="8" value="">

<input type="image" src="http://image.weather.com/pics/button_go.gif">

Any help/tips will be appreciated.
[Edited by TorontoGuy on 08-12-2002 at 12:20 PM]

Weather You Like It Or Not
I am hoping to put a live weather feed for birmingham, uk, on my flash navigator

is there a free service to do this, or could i take information from another page.

[F8] XML Weather
I am using XML weather from:

http://developer.yahoo.com/weather/

and have the following actionscript on frame 1 of my movie:


var my_xml:XML = new XML();

my_xml.ignoreWhite = true;

my_xml.load("http://xml.weather.yahoo.com/forecastrss?p=95720");

this.onEnterFrame = function() {

city_txt.text = my_xml.firstChild.childNodes[0].childNodes[6].attributes.city;

temp_txt.text = my_xml.firstChild.childNodes[0].lastChild.childNodes[5].attributes.temp;

conditions_txt.text = my_xml.firstChild.childNodes[0].lastChild.childNodes[5].attributes.text;

}


I would also like to dynamically place the corresponding weather icon from yahoo (ie partly cloudy, sunny, rainy), but don't have the slightest idea how. From reading the above URL, it has something to do with 'code', but i don't know how to call it into my Flash movie. I have limited xml knowledge, so be gentle. And, this is my first attempt at calling xml with actionscript. The above works fine for displaying the text forecast for city, conditions and temp. How would I display the corresponding graphic?

Thanks in advance -
sleepydad

Weather Help
I have a lil problem and some one said it can only be answered here, so am like let me give it a try. we have a local tv channel we run from school for student by students, and i do all the scrolling on screen from my pc, i want to take is a step further, i want to run an interractive weather forcast, which i want to physically input my self, so want i want to do is get a jpg file of the world map, make my screen 'full screen' and let about 8 values show at at points on the map, e.g maybe 23 by cairo...how can i go about that, can i have a text file outside that i can edit the values? so wne i finish i would just save the text file and then launch the flash file.

...any body with a solution?

Weather
Hi everyone! I am trying to make a weather feed that comes from yahoo weather. I am using the bronx new york weather rss which can be accessed at http://xml.weather.yahoo.com/forecastrss?p=USNY0172. The problem is that it does not play while hosted on any server but it plays locally on my computer. Is there something that i am missing. i added it to the system security allow domains section. Any help is greatly appreciated.
-Joseph Nwachukwu

Weather
I am looking weather "widget" for my site?
I Googled http://www.flashcomponents.net/compo...e_weather.html
Idea?

Weather
Hi everybody! This is my first post here.

I need flash weather for my web site (as2). I googled one - http://www.flashcomponents.net/compo...e_weather.html

any other?

Weather Channel
does any one know of a script that can bring the weather channels information for your location into your swf that will make live updates so you always have the current weather showing or any other weather program that will work with flash?

Weather Channel Is This Even Possible?
I have a standalone projector that I bring some swf's into from the web. now my ? is, is it possible to be able to get flash to show a weather forcast like from the undergroundweather.com the code the give me for my html page is.

<a href="http://www.wunderground.com/US/AR/Mountain_Home.html">
<img src="http://banners.wunderground.com/banner/default/US/AR/Mountain_Home.gif"
alt="Click for Mountain Home, Arkansas Forecast" height=60 width=468></a>

Please Visit Our Sponsors:

is there anyway to get a swf to show this without useing java script to pop up another window. I want it to show right in my swf

Need Weather On My Website
pretty vague thread title, no?

For starters, I'm an intermediate Flash Actionscripter, that is to say, I can do mouse trailer crap with my eyes closed yet cannot do a video game to save my life (but I'd go down swinging like a champ).

My question for yous guys is this: I want my website to display weather animation based upon the viewers location, is that possible?

Weather Script
I am looking to put weather on my website. Local conditions for a zip code. It would should temp and an image like full sun, prtly cloudy,ect. anyone help.??

Thanks

Weather Script
I need a weather script. This is a sample of what I want. I would like to have the main page I have given and the forcast, but would atleast like the main page with out forcast. Here is the link:

http://www.accrisoft.com/index.php?s...tegory=Contact

Someone help me out?

Thanks

Streaming Weather
Does anybody know how to stream weather into your flash movie from an outside source? Any help would be appreciated

Weather Forecaster
Is there a way to allow the world weather to be shown in a flash movie, that would be updated daily.
Ie . There is a picture of the world, the user selects a country and the weather for that country is displayed, nothing fancy just sun rain or cloud, somthing like that?????

Hows The Weather?
Hey all.

I am looking for some help making something to display the current weather of a specific city / zip / area, whatever.

I have been looking all over the web for the past 5 days, and I cannot find a good flash tutorial, or open source, or anything that will help lead me to this.

Do you know of any good tutorials, or any good sites to learn about making something like this?

PLEASE LET ME KNOW..

Thanks

.

[F8] Weather In Flash
Hi,
Do anyone know how to get local weather in flash using XML or others?
Any sample or code please.
Thanks
P

Weather In Flash Once Again.
Is there a way to do it without using PHP?

We're trying to do one for a screensaver that will ideally pull directly from the RSS feed.

Really don't care what site it pulls from as long as it:

Doesn't use PHP
Can be customized to show the weather for our office's zip
And we also want to ad our own custom graphics for both the weather and time of day.

Weather In Flash
Do anyone know how to get weether of your local area in flash application?
Any code, Sample please.
Thanks,
P

Rss Weather Widget
Does anyone know of a good rss Weather widget that will not only display text, but the appropriate weather image (sun, rain, etc.) like weather.com has? I'm not familiar enough with XML to parse out data. Any help you can give is appreciated!

Weather Problems
Thanks to LoungeActx, I figured out how to create a button for the falling snow effect in my project. My final code ended up being

on (release) {
for (k=0; k<8; k++) {
duplicateMovieClip(_root.snow, "Snow"+k, k);
}
}


Simple huh?! Well, now that I have a button to turn it on, I can't figure out how to turn it off. Could someone advise me on how to control my weather problems?

This is in Flash MX btw.

Thanks!

Weather Web Service
hi there, I was wondering how I can invoke some certain information about a certain city ( Mexico City ) using a WebService, I was trying with this one: http://www.webservicex.net/globalweather.asmx?WSDL but is not working, can someone helpme please?, I was reading any tutorial about web services within Flash MX Pro, but I missing something....

Thanks a lot!

Weather By XML And Flash ?
hi,

i search a small weather module, in flash +xml
where can i found a such file ?

RSS Weather Feed
I've been asked to build a website for a golf course which of (course) will be a great project but I would like to include a live RSS weather update with symbols if possible.

I have not attempted anything like this before and it would be great if you guys could post any help/links on how I could pull this off.

Thanks for any help.

Weather Forcast
Hi all,
is it possible to integrate a weather forecast in a flash movie, from the weatherforecast site I have this code:


Code:
<iframe width="120" height="160" scrolling="no" frameborder="0"
src="http://gratis.weer.nl/meteo/hptool/?cid=31X155&l=nl&
cityName=Amsterdam&style=3&v=nl"> </iframe>
this would be great.....if possible...

Weather Application
Hello everyone,

I'm new, I'm looking for some help for a little project of mine. Let me say that I'm a musician, with web development as an hobby therefore I consider myself a newbie even if I've been playing with Flash for a while now. I learned mostly from online tutorials and lynda.com titles (very helpful).

I'm trying to build a weather application using the free xml feed from weather.com. I found a php script that does it all, but the interface is just ugly html. I would like to create a nice Flash interface to display the data from the feed. I know how to load php with LoadVars but I looked at the php source and it's pretty complicated to me (I just know how to echo "hello world"). If I understood right, the xml feed from weather.com is loaded and updated into a database(I'm using mySQL) where php retrieves the data. The php script can be found at "http://www.notonebit.com/projects/weather/".
Can anyone share their knowledge to this poor guy eager to learn?
Thank you

Weather In Flash
Is it possible to put weather into your flash applications, maybe something associated with www.weather.com?

Just wondering, sounds like a pretty spiffy idea for your flash websites.

Thanks,

Bryan Hawkins

Flash Weather? I Think So
Alright .... I KNOW this has to be possible somehow!

I want to pass the current temperature to a flash movie based on a zipcode location that I will have on a .asp page, which will be passed to the Flash movie. So in flash I will have a var like "var currentTemp = temp" where temp is the variable passed into flash.

Does anyone know where I can find a resource for some guidance as to the .asp scripting or anything like that?

I have seen a php version, but unfortunately I need to use .asp.

Thanks to you!

Weather Widget XML
hi,
i'm developing a weather widget using the Yahoo's RSS, exemple at : http://xml.weather.yahoo.com/forecastrss?p=29577 .so i need to use the informations from that 29577 XML.

visit the widget demo at http://www.flashmedia.mxhost.ro/widget/
that one tries to load the XML from the url above. it isn't loading it... why ?



as far as for the offline version, works.
download the sources from http://www.flashmedia.mxhost.ro/widget/widget.zip and run the FLA and then publish. see? on your PC the widget works...
what's wrong with my hosting server ?

please help me making the online version work too.

Weather In Flash? - Rain...
Im tyring to find find a nice Rain effect in flash.
Anyone?

Dynamic Weather Information
hi.
I need weather information on my site. looking for dynamic weather information component.

could u please let me know if there is

regards

Weather Forecast Magnet
I am trying to add a weather magnet to my newly built flash site but have become very frustrated. Any help would be an absolute miracle!! this magnet will be inserted into a small area of the final flash piece and be displayed.

Here is the script that was sent to me from the weather network:

<!-- Begin Qwikcast.com -->
<iframe width='219' height='156' marginwidth='0' marginheight='0'
align='middle' border='0' frameborder='0' scrolling='no'
src="http://www.qwikcast.com/cgi-bin/sticker/qcmagnet.cgi?cust=7208&unit=C">
<table width='219' height='156' align='center' cellpadding='0' cellspacing='0'><tr><td>
<ilayer width='219' height='156'
src="http://www.qwikcast.com/cgi-bin/sticker/qcmagnet.cgi?cust=7208&unit=C">
<p>See <a href="http://www.qwikcast.com/cgi-bin/sticker/qcmagnet.cgi?cust=7208&unit=C">
Qwikcast.com forecast for Toronto, ON, CA </a>.</p>
</ilayer>
</td></tr>
</table>
</iframe>
<!-- End Qwikcast.com -->

[F8] Problem With PHP Driven Weather Box
I downloaded a cool little item called the "Weather box" fro here and want to implement it into my site, but it will not work. It included a PHP file, the swf, and the fla. I uploaded the swf, and php files to my server, set my area code where it said to in the php file, and apparently that was it. But it doesen't display anything but the big letter "F" for the temp, and two commas where the town, and state name shoud be. My server runs PHP scripts because my guestbook and shoutbox are PHP driven, so I really don't understand why it is not working.

Here is the code:

<---begin code--->

Code:
<?php
//Set your zipcode here:
$zip = 13148;

//You shouldn't have to change anymore.
define('WEATHER_URL', 'http://xml.weather.yahoo.com/forecastrss');
define('WEATHER_FILE', 'cache/weather');

class Weather {
var $data;

function getWeather($zip, $units='f') {
$units = strtoupper($units);
$path=WEATHER_URL."?p=$zip&u=f";
$this->data = @file_get_contents($path);
$fp = @fopen($file, 'w');
@fwrite($fp, $this->data);
@fclose($fd);

if(strlen($this->data) <= 0) return;

$attributes = explode('"', $this->GetTagAttributes('yweather:condition'));
$saved_units = explode('"', $this->GetTagAttributes('yweather:units'));
$location = explode('"', $this->GetTagAttributes('yweather:location'));
$saved_units = strtoupper($saved_units[1]);
$return = array();
$return['text'] = $attributes[1];
$return['temp'] = $this->convert($saved_units, $units, $attributes[5])."&deg;{$units}";
$return['image'] = $this->TranslateCode($attributes[3]);
$return['city'] = $location[1];
$return['state'] = $location[3];
$return['country'] = $location[5];

return $return;
}

function GetTagAttributes($tag, $skip=0) {
$start = -1;
for($i = 0; $i <= $skip; $i++)
$start = strpos($this->data, "<{$tag}", $start + 1);
if($start === false) return false;
$start += strlen($tag) + 1;
$end = strpos($this->data, "</{$tag}>", $start);
if($end === false)
$end = strpos($this->data, '/', $start);
return trim(substr($this->data, $start, $end - $start));
}

function convert($in, $out, $temp) {
if($in == $out) return $temp;
return number_format(($temp - 32) / 1.8, 0);
}

function TranslateCode($code) {
$time = date('G', time());
$night = ($time <= 5 || $time >= 20); // night is between 8 pm and 6 am
switch($code) {
case 39: return "ThunderStorm";
case 2: return "WindyRain";
case 43: return "Snow";
case 18: return "Sleet";
case 7: return "IcyFrozenSnow";
case 8: return "IcyDrizzle";
case 9: return "Drizzle";
case 35: return "IcyRain";
case 40: return "Showers";
case 13: return "LightSnow";
case 14: return "MedSnow";
case 15: return "WindySnow";
case 19: return "Dust";
case 20: return "Fog";
case 21: return "Haze";
case 22: return "Smoke";
case 24: return "Wind";
case 26: return "Clouds";
case 27: return "MostlyCloudyNight";
case 28: return "MostlyCloudyDay";
case 29: return "PartlyCloudyNight";
case 30: return "PartlyCloudyDay";
case 31: return "Moon";
case 32: return "Sun";
case 33: return "FairNight";
case 34: return "FairDay";
case 36: return "Hot";
case 44:
if($night) return "PartlyCloudyNight";
else return "PartlyCloudyDay";
case 45:
case 47:
if($night) return "NightThunderStorm";
else return "SunnyThunderStorm";
case 46:
if($night) return "NightSnow";
else return "Snow";
default: return "Unknown";
}
}
}
$weather = new Weather();
$weather = $weather->getWeather($zip, 'f');
echo "&city=$weather[city]&state=$weather[state]&country=$weather[country]&temp=$weather[temp]&pic=$weather[image]&condtext=$weather[text]";
?>
<---end code--->

I am also including the .fla for anyone who would like to attempt to diagnose the problem.

Thanks,

Display HTML Weather
I would like to place an HTML generated weather link in my Flash authored site. Following is the code that I have downloaded from http://netweather.accuweather.com/ad...gnup-page3.asp

//// BEGIN
"<div style='width: 120px; height: 60px; background-image: url( http://vortex.accuweather.com/adcbin..._120x60_bg.jpg ); background-repeat: no-repeat; background-color: #ffffff;' ><div style='height: 48px;' ><script src='http://netweather.accuweather.com/adcbin/netweather_v2/netweatherV2.asp?partner=netweather&tStyle=whteYel l&logo=0&zipcode=&lang=&size=7&theme=&metric=&targ et=_self'></script></div><div style='text-align: center; font-family: arial, helvetica, verdana, sans-serif; font-size: 10px; line-height: 12px; color: FFFFFF;' ><a style='color: #FFFFFF' href='http://www.accuweather.com/index-forecast.asp?partner=netweather&traveler=0&zipcode =' >Weather Forecast</a></div></div>"
//// END

Is there a way to do this? An external AS file perhaps??

Thanks in advance for input -
sleepydad

In Need Of Graphic 7 Day Weather Forecast Help
I'm looking for any knowledge on how to produce weather content similar to AccuWeather's SWF modules.

http://www.accuweather.com/adc2004/p...talsignage.asp

Can anyone point me in the right directoin?

~ Brian

External Source, Weather Help.
Ok bare with me whilst I confuse you loads!

I have my seasonal island which cleverly changes itself in time with the natural world, i.e. today the island looks like its the middle of autumn.

Now I'm trying to install a weather system. I currently have one, where I just randomly placed Rain and Snow movie clips at different days.
For example, on the 4th of september, there is a rain movie clip, that will play all day of the 4th, however this means every 4th of september there will be rain.

I was wandering if there was a way to reference to like a weather website, and create like a complicated if statement, so it only rains when the weather website says there will be rain...

does this make sense?
Does it sound aty all possible?


Thank you.

Time/weather Rotation
Hello,

I'm trying to do some research. I own a digital advertising company and have ads that rotate in establishments...but what I want to do is on my logo, have it rotate, and on one time it'll show the current time, and when it rotates to the other side it'll show the current weather for that city.

Is there any sort of plugins or something someone could help me with to plugin to flash to do this sort of thing?

Any help would be appreciated,

Eric

Flash Weather Baby
Alright .... I KNOW this has to be possible somehow!

I want to pass the current temperature to a flash movie based on a zipcode location that I will have on a .asp page, which will be passed to the Flash movie. So in flash I will have a var like "var currentTemp = temp" where temp is the variable passed into flash.

Does anyone know where I can find a resource for some guidance as to the .asp scripting or anything like that?

I have seen a php version, but unfortunately I need to use .asp.

Thanks to you!

HTML Weather In Flash...
Is it possible to load a weather URL like the weather channel lets you do in HTML - into flash.
You know the ones with the pretty pictures and and temp.

thanks
-T

Crossed Domains: From WEATHER.com
Hello everyone:

I hope someone else passed through this point before: I have found many posts in google about this but no one has an aswer untill now (unless I have not reached it...) Well... to make it short:

I import the XML data provided by Weather.com (I suscribed before and etc etc.. everythying you nedd) The point is, I can display that XML data perfetly well when I run my application on the PC, but as soon as I upload this to the server it does NOT work any longer..... why ? I could find out that since Flash 7.0 appeared... it is forbbiden to import data from other websites.... but what do I do in this case ? because in this case they approve that data import.... !!! they even have the technical points to be aware of....

My server is PHP, if you know how to help me, please let me know, I will appreciate it, and so will do the rest of Flash-PHP community people.... ;)

Thanks in advance...

Weather Channel Desktop
Hi.
I had to do a system recovery.
I re-insalled all programs which worked fine before.
When installed the free version of the Weather Channel Desktop, it does not display the information on the pop up window.
I noticed that this happened after I installed the new version of Media Flash Player. All I get is a blue screen.
It had always worked with the previous versions.
Do I have to install something else for it to work?
I've tried contacting the Weather Channel but they do not respond.
Thanks.

Weather Data Question.
I have an idea for a weather app. It would conceive of a small square (about 160x160) and in the square you'd have text at the bottom telling you the time and temperature. The animation at the top of the graphic would reflect the weather. (ie. Snowing if it was snowy, raining if it was rainy, sunny if it was clear, etc.)

Any ideas as to where I'd get data to update the Flash app?

Any suggestions would be very appreciated.

Loading Weather.com Temperature Bar Into The .swf
i feel like this is possible, and i've tried a variety of ways from getUrl() to loadMovie() commands to bring/load the HTML that contains the script from weather.com( to get the current temperature of the area) into a container in my flash website and i cannot get it to load any which way.

this is all the code in the body of the HTML that is needed.
Code:
<script src='http://voap.weather.com/weather/oap/11779?template=TRVLV&par=1019369021&unit=0&key=e1fca39755b6808f7d38e2695a1019bf'></script>
im trying to get this into a container that i have in my flash website called weather_cont. Any help or suggestions would be very appreciated.
thanks.
peace.

How Would I Have Live Weather On My Website?
I have a couple of different places I could use as a source to feed the live Temp/Weather outside, but how can I link it to my own site using Flash? thanks

Joe

Weather Variables In Flash Mx
hi there,

I was wondering if it is possible to get the accurate weather (temperature, cloudy/sunny/rainy/...) from an existing server somewhere into a flash mx file?

For those who have windows vista already: there's a weather gadget that shows the temperature and a graphical representation of the sky outside, at that particular location, at that particular time (so very accurate).

First problem: where can I find a server who provides me of this data?
Second problem: where to start with the actionscript?

I really hope that someone can help me out cause I'm completly stuck.

thanks !

Creating A Weather Script
hello to this forum!

I wonder if anyone has managed to make a weaterscript with xml and flash?

Weather Data Question.
I have an idea for a weather app. It would conceive of a small square (about 160x160) and in the square you'd have text at the bottom telling you the time and temperature. The animation at the top of the graphic would reflect the weather. (ie. Snowing if it was snowy, raining if it was rainy, sunny if it was clear, etc.)

Any ideas as to where I'd get data to update the Flash app?

Any suggestions would be very appreciated.

Add A Weather Underground Sticker To Fla
Help! I have had a weather underground sticker on my site for a few years. Now I am changing to a flash site and since the data displayed changes I'm stuck on how to add it. I tried using Layers in Dreamweaver to display the sticker above the flash, but it didn't work. The basic sticker can be seen at http://www.ronbigus.com. Adding a link to a button isn't a problem but when the link is sending dynamic data what do you do, Action Script is new to me, but I'm guessing that is the way to go. Anyone already done this?

Creating A Dynamic Weather Map?
Hello, I don't post much, but I'm a huge fan of the site and have been a member for a number of years.

Having said that, I'm curious to know if there is a way to build a weather map, which updates after a certain duration, sort of like this:

[url}http://www.weatherbank.com/products-...-forecast.html[/url]

I'd also like to see temperatures. Would AS 3.0 be the right way to go?

Thanks!

Mortgage Rates And Weather
Is there a way to display mortgage rates and weather forcast in flash. If so how, is there any source files or turtorials?

Thank You

Copyright © 2005-08 www.BigResource.com, All rights reserved