ActionScript 3.0 :: Create A News Rotator That Pulls Info And Images From A XML File
Nov 10, 2009
I am trying to create a news rotator that pulls info and images from an XML file.I made something similar a while back which pulled just the headlines which worked great and I am trying to adapt this same idea to a current project. pull all the info from the XML and push them into separate arrays based on the type of information it is. ie title, description, image etc.From there I have a function which is supposed to display the all of the info and another which cycles through it based on a timer.Like I said before, this worked great with just the headlines, but when trying to add images its getting thrown off. The function which intends to parse the data and pushing it into separate arrays.
Code:
function onLoaded(evt:Event):void {
xml = new XML(evt.target.data);
var il:XMLList = xml.channel.item;
[code]....
I'm aware that it has something to do with either how the info for the images is being parsed (or not), and/or how I am going about displaying it.I was able to write a separate function which displayed one image as intended, but then wouldn't cycle through as the news changed.
View 1 Replies
Similar Posts:
Aug 2, 2006
I'm trying to create a dynamic news section that works off of a XML file and I'm running into some problems. Here's the code I'm using right now
Code:
//load XML
xmlContent = new XML();[code]....
It seems to duplicate the movies correctly, but it won't load the XML into the corresponding text boxes I've created. I've included a link to the source files as well if anyone has a minute to take a look.http:[url]....getting the date from the attributes of the news item I'd like it to go in the "date_txt" box within the news module clip.
View 3 Replies
Sep 9, 2010
I'm working on a project and attempting to create a dynamic news page by loading from an XML file. Everything seems to display fine for some people, for others it loads every dynamic text field with an instance path such as "_level0.instance1.instance30.instance45.conte ntMa in.Body1".
Here's the code I'm using:
Code:
function loadXML(loaded) {
if (loaded) {
_global.atitle1 =
[Code].....
View 1 Replies
Jul 14, 2009
I have experience with flash slideshows, but I'm trying to find out if there is one that will read images from a folder. Basically I'm using a cms with a gallery plugin. I would like to be able to view images managed with the plugin in the flash slideshow.
View 3 Replies
Jan 15, 2009
I have a flash image rotator that is controlled by an XML file that looks like this:
[code]...
how do i add links to each of these images
View 1 Replies
May 9, 2008
Im trying to make a horizontal scroller, that pulls images from an XML document, and scrolls them infinitely.I have 2 problems with this and I have been looking everywhere for a tutorial, or example that shows how to do this and I always find something that is close to what I want but not quite.Here is what I have so far:
Code:
var mcLoader:MovieClipLoader = new MovieClipLoader();
var mcListener:Object = new Object();[code]....
What I'm wanting to do is instead of using 490 (underlined), I want to be able to get the width of each loaded image so that I can line up the next image right up against it regardless of its width (490 just happens to be the width of all of them right now).I'm trying to use the onLoadInit() function, but I know I'm doing something wrong. When I try and trace my mainLoader variable, it traces the right amount of times, but they are all the last object in the group.What do I need to do to be able to get the widths of each image as it loads, then use that variable to position the next image right after it?
also (a semi unrelated help request), what I'm doing right now is loading them ALL in creating one giant line of images, then loading in another giant line of images and just alternating between the 2 each time one is almost to the end of its length. Is there a better way to do this so that only the right amount will load, and scroll, at the beginning adding the one right before it enters stage, and as they move off stage they are removed, then when it's near the end it just adds the first one back to the end?
View 6 Replies
Jun 5, 2009
I want to create an image rotator that looks similar to the one in the upper RHS of joinred dot com. I'd like it to have images that are a bit bigger than the one on that site. However, I like the thing about them coming in from the right, as well as the effect, being a bit distorted and then becoming clear.
View 1 Replies
Apr 22, 2011
I want to create a slideshow banner that will showcase our products. The slideshow will contain the image of the product, the name, the price, the item code and the link when someone clicks on it. Each week we update the best sellers and it can be from 5 to 15 different products. Similar to what we have now in our website www.deiequipment.com which now is static, we want to animate it and rotate the products like a slideshow.The problem we are encountering is that we have to manually update the slideshow content.
We would like to know if there is a way through scripting or catalyst to connect to a database and simply update all these fields automatically. So for example if the database has 5 items, automatically will pre-fill each field listed above and the slideshow will have 5 products.
If we update the database now with 10 products, to update automatically. That way we can create 1 slide show, the time it takes to rotate to the next product, and add simple button controls to the slide show for next and back that will simply go through the loaded items.I tried to do a research on how to do it online but some takes me to scripting, others to catalyst dabases, but none are specific to what I need.As a note, the image will just be an image holder that will be updated with the image field in the database that points to the URL location of the image.
View 10 Replies
Sep 30, 2011
I want to create a cube with images from an xml,..that will rotate to one side of it and show me an image..stay for a while then rotate again to next image-side..wait etc.
View 1 Replies
Jan 18, 2011
I'm trying to create an image rotator in flash that is powered by XML that just continually rotates through the images (fading into an image and fading out, and then fading into the next image, etc).I've managed to load the XML file and get the location of the image files for each image:[code]and I've managed to load the last image in the XML into a movieclip by putting this line:imageHolder.loadMovie(myImage[i].attributes.image); under the var imageURL = myImage[i].attributes.image line.I can't work out how to:
1. Display one image at a time instead of just the last image in the XML file
2. Fade in and out between each images (I was trying to use Tweenlite to do this and think I can get it to work once I know how to do the above point)
3. How to continually repeat through all the images.
View 2 Replies
Nov 9, 2009
I want to put a flash banner(slider) to show a bunch of products iteratively. And I want it to allow interaction so the user can interrupt image looping and choose what she wants to see and what images to show how long it will be shown should be configurable. I already googled for 'flashe banner / slider' but with no luck. Is there any open source projects that can offer this kind of feature? Or tools that can help me to create one.
View 2 Replies
Jul 16, 2009
I have a rotaing menu that loads in images from an xml file, I would also like it to load in text info from the same xml file to the left side of the images that load in. In my main .fla have created a movieclip and called it 'textInfo' and inside that I have two dynamic text fields called 'headerText' and 'bodyText' where I want to load the text in. this is what I am using to loading in the text in my actionscript, is this correct?
[Code]...
View 22 Replies
Feb 20, 2008
I've built a flash photo gallery that pulls image urls from an external XML file. The gallery has different image catagories that load their own set of images.The user decided which catatgory they'd like to view by clicking an HTML button in the flash movies parent page...using javascript, this button click sends a variable to the root level of the flash movies with the new XML location...
Trouble is, onces the initial XML file is loaded, the movie has no need to refresh (and read the newly sent variable) ...*Unfortunately the catagory buttons MUST be outside the movie on the page...
View 4 Replies
Jun 5, 2008
I found a script at on the web that emulates the news scroller found atI would like to add images to each news headline so it can replicate the effect found at
Code:
stop();
//
[code].....
View 2 Replies
Sep 4, 2010
I am trying to create a news scroller such as the one on espn.com where you have a scrolling news component that can contain images and or videos and links to news stories stored in the database.
View 2 Replies
Jan 8, 2010
I want to implement an XML news reader with images and video links( youtube for example) in as3. Does anyone know where i could find and example or at least, how to read video links from an XML file in as3?
View 2 Replies
Apr 6, 2005
I am creating a flash app for a soccer website I'm doing for me school. What I have so far is a main section where news can be viewed and stuff.I have another part of the app that allows for someone to log in and add new news for everyone to see on the main screen. Is this possible without FlashCom and/or db?
View 4 Replies
Apr 6, 2005
I am creating a flash app for a soccer website I'm doing for me school. What I have so far is a main section where news can be viewed and stuff. I have another part of the app that allows for someone to log in and add new news for everyone to see on the main screen. Is this possible without FlashCom and/or db?
View 4 Replies
May 17, 2010
I am working on the news ticker module (AS2) where I have to fetch news from xml and populate that news headings into four text fields and these 4 headings will stay for a while and fade until last record. this process will continue.
View 0 Replies
Mar 24, 2007
Making an XML news reader based off of senocular Squirrel XML news.
I'm using Fuse and wanted to target the dynamic text and or background portions of the headline section.
However, this movie clip is attached to the menu_mc so I'm stumped as to what I should exactly target for the fuse sequence (or any mx.transition/zigo engine based code-tweening process for that matter).
I've attached the files in a .zip for people to look at (and possibly conquer my problem!
View 3 Replies
Aug 1, 2007
how to create a dynamic news ticker like one of these? Only that it would scroll longer sentences? Of course the first idea is just load single line TextField and tween it across the screen beneath a mask. I don't like this because
a) It's retarded
b) Your swf width is quite long even if you don't see it, it's there.
c) It's retarded
I'm trying to think up a better solution. So far I haven't thought of anything better (does that mean I'm retarded?). Some other brain stormed ideas could be parsing each word in the String into it's own Sprite, as BitmapData, and sort of train tweening those, that was you can dispose each after it's cleared the screen. This seems like too much work, and potentially draining on the system's resources, having to create new instances, and repeteadly add them to the display list, and such.
View 10 Replies
Jun 14, 2005
how to create a news section using xml in flash?
View 2 Replies
May 12, 2009
I wanting to create a basic news scroll / ticker like this http:[url]....What's the best way of achieving this to get a continuous smooth animation.
View 3 Replies
Oct 13, 2009
How would I do a text movie like the one on this home page? http:[url]....I've tried before, but have had no success. I can create the swf file and fade images in and out. In the past I've put one line of text on one image, then another line of text on another image, but when I fade the images in they just cover up the prior one.
View 1 Replies
Aug 30, 2010
create a slideshow that load images via .xml file.
[Code].....
View 2 Replies
Jul 17, 2009
I wanted to add a second news box under the first one and have it pull the first two news items in the xml file and have it displayed on the movie. Currently it is putting the first news item in both news boxes.ction script so that the second box is actually the second "<news> tag". From the tutorial I removed the <info> <author> and <comment> tags.
View 0 Replies
Jul 11, 2011
I was wondering if it's possible to include an swf within a javascript carousel that currently just contains stagic images. What I'm looking to do is include a flash animation within the carousel. I guess I've got two main questions: Is it possible to cycle through flash files in the same way as an image? How would I get the javascript and flash to interact so the flash file would know when it had been selected?
[Code]...
View 1 Replies
Oct 24, 2009
im trying to create a flash file that is randomly showing different objects/images, i believe i have the correct codes although i have encountered an error.
[Code].....
View 3 Replies
Jun 3, 2011
I am trying to create the sample file for loading the video images with thumnail.But i don't know how to create thumnail for video file (using video component).give any tutorial and give some sample files.
View 1 Replies
Jul 15, 2009
I have a rotataing menu that is driven by xml images. the images all load in, but I would like to have a little text info at the left side of each image as it rotates.I understand that you create dynamic text fields, which I have done in my fla that then somehow link you to the xml where the text info is read from, but how the AS3 script goes for this I do not know?I would like the text to be fixed with the image and rotate by the side of images and not pop up like a tooltip.I am working with example files I received from soulwire, which contain displayObjects so I think it has to be done like that?I am new to AS3 so I don't really understand how it works, would anyone beable to direct me to somelinks on how to do this or be so kind as to take a look the example files I have uploaded.URL...
View 3 Replies