views:

195

answers:

2

I am making a photo slideshow in flash and would like to be able to load images dynamically from a folder. So that whenever i have a new photo i can just stick it in a folder and have my swf file read from that folder and update the slideshow. Is this doable in actionscript 3.0? if so any pointers would be helpful. thanks!

+2  A: 

Sounds like this would be more server-side logic than Flash logic.

Your Flash program would need to ask the server for a list of images to load (which the server script would get from directory). You would need to choose a data exchange format (plain text (e.g. one filename per line), or XML, or whatever is easiest for you to work with). The server script would send back the list in the chosen data format. Then your Flash program would load all the images in the list, and present them to the user in a slideshow.

The trickiest parts of your problem would be getting the list of images in the directory (depends on which language you're using server-side, but shouldn't be too difficult), and getting Flash to communicate with the server asynchronously (check out URLLoader).

Cameron