ActionScript 2.0 :: Dynamic Slideshow - Loading Images Using XML Info From Array

May 25, 2009

I've constructed a dynamic slideshow using ActionScript 2.0 and PHP/MySQL. The reason for this, aside from update purposes, is that the slideshow will eventually display over 200 images. Thus, to save loading time and bandwidth, I decided to use PHP to pull ten images from an SQL database, formatting the output in XML. The slideshow itself works fine. Unfortunately, there are a couple of issues I need to address; my ActionScript is extremely rusty, so much of my work's patchy.

The code's displayed below:
import mx.transitions.Tween;
import mx.transitions.easing.*;
var myShowXML = new XML();
myShowXML.ignoreWhite = true;
myShowXML.load("getData.php");
[Code] .....

The code in red is my main focus. It's the loop which loads all images as movie clips using the XML information from an array. The loop loads all of the images, making them transparent before the presentation begins. What I would like to do instead, to save loading time, is to load the next image while the current one is displaying. The function "moveSlide" controls the transition of the images, so I'd imaging it'd be best to plade it in there.

There's already an incremental variable being used, with _root.target_mc, for removing transparency from the current slide. The code in blue is also nagging me quite severely. I retrieve the next chain of slides by simply contacting the PHP script again. The only way I could think of doing that was to refresh the slideshow (this is done COMPLETELY in ActionScript, with nothing on the stage). Unfortunately, I could only work out how to reload the whole video.

View 1 Replies


Similar Posts:


ActionScript 2.0 :: Images - Dynamic Loading Into Array And Displaying

Apr 11, 2005

I'm trying to create something that will load a bunch of images into an array and then be displayed whenever needed via using the attachMovie() function.

Code:
for (var i=1; i<list.length; i++) { //list is an array full of urls to images
_root.createEmptyMovieClip("img"+i,i);
loadMovie(list[i], "_root.img"+i);
}

I dont think this is what I want because I don't actually want the images to appear right here (this is the loading part). What I want is each image to be in a separate symbol with a unique identifier so that I can create them dynamically during runtime.

View 1 Replies

ActionScript 2.0 :: Preloader SWF Setup - Loading Images / Info

Oct 8, 2007

I'm about to make a preloader of sorts, but have run into a problem because I have multiple SWFs being externally loaded in different locations. [URL]

As of now, it's setup like so:
Main.swf - has the scrollbar, loads body.swf into scrollbar container
Body.swf - has the layout, buttons, etc. Loads illus_finished.swf, illus_sketchbook.swf, etc.
illus_finished (and all other work files).swf - dynamically loads XML and images/info.

So basically, its one big swf that loads the content swf. The content swf loads the work swf's - which load the xml, images/info. I think I might load all the swfs from one file somehow, but I'm having trouble targeting into MC's of loaded swf's.

Should I set up a preloader swf, and somehow preload all the swfs into the browser cache? (I dont know how to do this, esp since I'm loading into a target, and not a level#) This way I wouldn't have to change how my movie is setup.

Should I take all the loading instances out of all my files and load them all from the first movie - and stick the preloader in THAT file? I can't figure THIS out, either, because I can't seem to target movieclips in loaded SWFs.

View 1 Replies

ActionScript 3.0 :: Getting Error Info On URLRequest When Bulk Loading Images

Feb 18, 2010

I'm using a bulk image loader from FlashAndMath. The code has you send a list of images to load and it simultaneously attempts to load all at once, adding each load req to a list.

My problem is that when one doesn't load and throws an error, I don't know which load request failed. Are there built-in ways to get it to report what image it was trying to load, or at least which of the load requests threw the error? I tried doing an event.contentTarget.content.name and it reports an instance #, but not the name I tried assigning when I called the URLRequest.

View 6 Replies

CS3 Loading Random Images Into Slideshow?

Jan 12, 2010

i am using a slideshow template that I purchased and I wanted to get the images to load randomly, I contacted the author but he wants me to pay him extra for this and I have no money left for this project.basically, I'm looking to add a line to this as2 file that would make the images load randomly without repeating and then start over when the cycle completes. I tried putting in an array but it caused all kinds of errors.

View 8 Replies

ActionScript 3.0 :: Slideshow - Images Loading All At Once

Oct 6, 2011

I'm writing a flash site for my wive's photography site.translation.I'm not getting paid. I wrote a slideshow that works great except that the images load all at once. It seems to me they should load one at a time, but they don't and I don't know why. It really slows down the loading of the page. [code]...

View 3 Replies

ActionScript 2.0 :: Loading Images Only Once For A Slideshow?

Jun 2, 2008

I'm building a slideshow using only ActionScript, but the computer running it will only have access to the files when the show is first started. So I need to somehow load all the images initially, and call on them from within the file itself from then on.

View 3 Replies

Actionscript 3 :: Dynamically Insert Object / Array Info In A Dynamic Textfield?

Jan 25, 2012

I have a load of objects with arrays in them.

var tabData0: Object = new Object();
tabData0.tab1 = new Object();
tabData0.tab1.names = new Array();

[Code]....

I want to combine this output with a few more to refer to my object / array. The remoteHolder contains the value I need to know which object (tabData0, tabData1, etc) to retrieve the info from.

tabHolder['btn' + i].titleHolder.titleField.htmlText = all['tab' + tab].names[(i-1)];

But get this:

ReferenceError: Error #1069: Property tab1 not found on String and there is no default value.

View 1 Replies

ActionScript 2.0 :: Passing Info In Array To Dynamic Text Field On Rollover?

Aug 20, 2007

I am trying to pass information to a many dynamic text fields when rolling over various movieclips that are generated using a loop. I have tried everything I know but can not get pahting to work prpoerly. The rollover works in that the curser changes by does not execute the lines of code within the in line function.(see red, bolded text (towards bottom) for problem). the Attached zipped swf is what it looks like as is.

Code:
//how many floors are there in the building?
var floors:Number = 25;

[code].....

View 2 Replies

ActionScript 2.0 :: Made A Script For Slideshow An Array Of Images?

Oct 31, 2005

i've made a script for slideshow an array of images, with fading images. I'm trying to figure out what's wrong with my script, why it has small pauses between images.

here is the script, on the first (and only) frame of the movie:

[Code]...

View 1 Replies

ActionScript 3.0 :: Loading Images To Slideshow - URL Not Found

Apr 2, 2009

I am having a little trouble loading images to a slideshow. I have all of my paths correct and all of my images named correctly. I get this error:
Error #2044: Unhandled IOErrorEvent:. text=Error #2035: URL Not Found.
The code I am using is attached.

View 1 Replies

ActionScript 2.0 :: Xml Slideshow - Not Loading Images Consistently

Sep 16, 2008

I modified an existing slideshow script so that it would like to a page when you clicked the image. However, the images do not always load up in the correct order, but the links and descriptions do, so if you click an image it takes you to the wrong page.

It changes when you refresh the browser and acts differently in ie to firefox - in ie it is usualy incorrect the first time, then goes ok once u refresh. The link to view is: [url]. and the actionscript is[code]...

View 6 Replies

ActionScript 2.0 :: Dynamically Loading Images Into Slideshow?

Jul 11, 2005

I wanted to create a slideshow in Flash MX 2004 using the instructions given in the Photo Gallery Using XML and Flash tutorial on this site but I wondered if someone could tell me if I would be making the right decision using this technique considering the following: My slideshow will be used for a menswear clothing company, so the images will need to be on the left and then on the right would be all the information relating to that image/item of clothing - no problem so far but...

I've already set up a slideshow the "long way" with 20 or so images as well as their related information on different frames - the images are on one layer and the descriptions are on a separate layer also. I've got a couple of buttons controlling the navigation back and forth between the frames and I've also got a preloader on frame one to load everything beforehand. The problem is that I'm worried about people on slow connections, that they'll have to wait an unreasonable amount of time before all the images are downloaded, so I thought that using the dynamic method outlined on this website would be useful and save downloading time, but I wondered if it was possible to keep all the information relating to the images on separate frames and just have the images import dynamically? The reason for this is that the information to the right of the images is quite long with information given about style numbers, sizes, descriptions and even colour square graphics are inserted to display available colours etc, so I'm thinking that it's probably not practical to dynamically load this information but to keep them on their separate frames as I have them at present, and also all this information is on top of a simple graphic interface on which I'd like to keep the info vertically centred. So is there a way to have the images load dynamically, and if so how would I get them to load correctly onto the right frames that match their relevant information? Can someone tell me if it's possible to use the information in the abovementioned tutorial to do what I want? Or can you tell me if I'm choosing the right method - I mean considering all the information including colour squares that will appear to the right of the images, do you think it's impractical to choose the Photo Gallery Using XML and Flash method? Also I'm not even sure if loading the images dynamically will improve things - I mean the images still have to be downloaded right - will loading them dynamically just mean that they'll load one at a time as the user navigates through the slideshow and if so won't this cause delays for the user in that they'll have to wait for each image to download before they can proceed forward to the next item?

View 1 Replies

Slideshow Movie Has Stopped Loading All Images And Stalls

Jun 4, 2009

I made a basic slideshow that loads and plays photos with comments from an xml file. I've just uploaded some new photo's and edited the xml to include them but now flash stops while loading the series of photo's and just stalls. Removing the files from the xml does not work either and now I have no movie. Tried various was of uploading etc and nothing works, the movie runs fine in testing locally. It's extremly anoying as it was designed to be very simple to update with new images via the xml.

[Code]....

View 10 Replies

Flash :: IDE - Dynamic Slideshow / Gallery - Point The File At A Folder Of Images

Aug 24, 2009

Im a noob at flash and am stuck making a photo sideshow application. I would like to be able to point the flash file at a folder of images, which are then all put into the slideshow and played through.

View 1 Replies

ActionScript 2.0 :: Text In A Slideshow - Make A Basic Photo Slideshow With External Images

May 29, 2008

i have a question about text in a slideshow. i know how to make a basic photo slideshow with external images. but now what i want to do is add 4-5 paragraphs of text next to each photo (with possible scrolling). the text will be different on each photo.

View 1 Replies

ActionScript 2.0 :: Make An AUTO Button Which Will Make A Slideshow,showing All The Images In Array?

Jan 23, 2007

this is my code for photogallery.there will be 61 images loaded in this array.how can i make an AUTO button which will make a slideshow,showing all the images in array?

arrayrow = new Array()
arrayrow=[
["00.jpg","0","sajkad","hjsgadhj"],[code].....

View 5 Replies

ActionScript 2.0 :: Incorporate In A Xml Based Slideshow(slideshow.zip) To Show Image Loading Process?

Feb 6, 2008

I have created a pie preloader(preloader.zip) which is working fine. Same preloader I am trying to incorporate in a xml based slideshow(slideshow.zip) to show image loading process but some how I got stuck. I am new to flash. Suggestions are welcome.

1. How to solve the problem of preloader2. Is it possible to integrate everything in a movie clip (including AS). I mean no AS on main time line but inside the movie clip. It would be much easier then to to create multiple slideshows by duplicating mc and changing the xml file.

View 1 Replies

ActionScript 2.0 :: Loading An Array Of Images?

Sep 14, 2006

Right now I am working on a game where I need to have 19 pieces revolving with 19 different MCs in them. The code I have can accommodate the movement and 19 pieces, but how to get 19 different ones in there - just one with 19 duplicates.

I thought if I addressed them in an array, I could tell my emptyMovieClip to load them into itself with individual MCs. I'm sure I'm on the right path, but it's not working yet.

My array:
anames = new Array (mcAnniePiece,
mcAlbertPiece,
mcAshleyPiece,

[Code].....

View 2 Replies

ActionScript 3.0 :: Loading Images From An Array?

Dec 17, 2009

I know there are tons of tutorials out there about loading images from an xml file and creating a slide show. I can plug and play with those pretty good. However I would prefer it if I could start writing code myself. I am starting basic and each day working on adding code to a project.

Here is a made up app. Basically I have created three loaders that add an image to each one which I put into an array, cause why not. I have two event listeners one for an on stage click to load an image, and one a timer to load an image. The next thing I would like to try and do is load one image for a period of time, then load another etc.

So would I need a loop that loops through the array somehow connected with a timer?

public class array extends Sprite
{
//Create Loaders
private var imageOne:Loader= new Loader;

[Code].....

View 1 Replies

ActionScript 2.0 :: How To Get Flash To Keep Loading Images In Array

Feb 26, 2009

So I've got an array of images,
Code:
pixArray = ["Images/Architecture/Hospitality/01.jpg", "Images/Architecture/Mixed/01.jpg", "Images/Architecture/Office/01.jpg", "Images/Architecture/Performing/01.jpg"];

It's part of a slideshow, loading one image, waiting 4 seconds, then it loads another, etc etc. The problem is, between each image, it has to load. I'm trying to find a way to get flash to keep loading all the images in the array until they're all loaded, something to the effect of: On the completion of the loading of the first image, start loading the second image in the array. On completion of loading that, load the third image, etc, until there are no more.

I already have a variable that tells it how many items there are as well:
Code:
var total:Number = 4;

View 3 Replies

ActionScript 3.0 :: Loading Images Into Array After URL Loaded

May 25, 2010

I am loading my images into an Array after my url is loaded
Code:
function urlLoaded(event:Event):void {
urlLoader.removeEventListener(Event.COMPLETE,urlLoaded);
xml=XML(event.target.data);
xmlList=xml.children();
[Code] ....

It is arrayThumb I am interested in, I wanted each each to be placed into a location within this Array. I then wanted to do
Code:
thumbArray[0].addEventListener(MouseEvent.CLICK, click_handler1);
function click_handler1(e:MouseEvent) {
trace("IMAGE CLICKED");
}

But when I try this, I get
TypeError: Error #1010: A term is undefined and has no properties.

View 2 Replies

ActionScript 1/2 :: Images Loading From An Xml - Randomize The Array?

Dec 11, 2009

I have a flash file that loads images from an xml file. Is there a way to make the images load randomly? I would like a different image to start every time it loads. here is where the xml is pulled in...

[Code]...

View 3 Replies

ActionScript 2.0 :: Loading Random Images In An Array?

Aug 30, 2007

I am developing an advertising site and the site has three seperate flash areas. on the top of the page i have created a movie clip and successfully managed to get the images to load randomly. GReat...Here is my dillema in the other three areas that consist of seperate movie clips i want to load images that have been numbered sequentially like p1.jpg etc... what i want to do is to have the images load randomly, and be positioned in the movie clip where i want them to appear dynamically... then if the user clicks onto the next set of images, i need to be able to tell whether one of the previous images has been displayed, if it has, not to show it again.

View 2 Replies

IDE :: Get Flash To Keep Loading All The Images In The Array Until They're All Loaded?

Feb 26, 2009

So I've got an array of images,

Code:
pixArray = ["Images/Architecture/Hospitality/01.jpg", "Images/Architecture/Mixed/01.jpg", "Images/Architecture/Office/01.jpg", "Images/Architecture/Performing/01.jpg"];

It's part of a slide show, loading one image, waiting 4 seconds, then it loads another, etc etc. The problem is, between each image, it has to load.I'm trying to find a way to get flash to keep loading all the images in the array until they're all loaded, something to the effect of:

on the completion of the loading of the first image, start loading the second image in the array. On completion of loading that, load the third image, etc, until there are no more. I already have a variable that tells it how many items there are as well:

Code:
var total:Number = 4;

View 1 Replies

ActionScript 2.0 :: Loading Images From Array Randomly?

Jan 18, 2010

I am trying, with this code, to first, shuffle the order of the images in the array so their loading sequence is never the same when the page is reloaded.Then, im trying to have the shuffled array open one at a time, image by image, at a set interval.

Code:
Array.prototype.shuffle = function() {
for (i=0; i<this.length; i++) {

[code].....

View 6 Replies

ActionScript 3.0 :: Loading Dynamic XML And Images?

Jan 8, 2012

I have written the following to send variables to PHP which searches a MySQL database and returns the results in XML. However for the life of me I cannot get the XML data loaded into the Movie Clips of my Flash site.Is there an obvious problem that I've overlooked?

ActionScript Code:
var imageDir:String = "Images/";
var getImage:XML;
var imageList = new Array();
var newPic:MovieClip = new MovieClip();

[code]....

View 5 Replies

ActionScript 2.0 :: Loading Images From Dynamic URL

May 15, 2004

I have 3 movieClips on the stage. I want this to load images from urls that I have withdrawn from a php script that randomly selects from stored urls in the database. I want to load one of these into each movieclip. Here is the code that I have, but it doesn't work. (Btw, this is on a frame of the movie)

PHP Code:
loadText = new LoadVars();
loadText.load("generateQuiz.php?week="+_root.week);
loadText.onLoad = function() {
j = 1;
sortItOut();
[Code] .....

View 4 Replies

AS3 :: Flash - Loading Multiple External Images Into An Array?

Apr 2, 2011

Trying to pick 4 images randomly and load them into and array and then show them using a timer when all 4 images are shown 4 more images will be loaded again. here is the code:

var images : Array = new Array();
var rndNumbers : Array = new Array();
var imageLoader : Loader;

[code].....

View 1 Replies

ActionScript 3.0 :: Passing String Of Images Into Array And Loading Into BMP

Jul 5, 2010

I am trying to pass a string of images into an array and then load each image dynamically into a seperate bmp. The code is as follows:

ActionScript Code:
package{
import flash.events.*;
import flash.display.Sprite;
import flash.display.Bitmap;
import flash.display.BitmapData;
[Code] .....

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved