I thought you guys might get a kick out of this.
http://www.mustardlab.com/developer/test/new/
The directory includes the following files you can download if you want
gallery.fla gallery.swf gallery.php index.php
**jpg images
what happens is the swf file loads in gallery.php which contains the following code
<? $xml = '<?xml version="1.0"?'.'>'; $handle = opendir("."); while ( ($file=readdir($handle)) !== false ) { if ( !is_dir($file) ){ $pic = @getimagesize($file); if($pic != false && $pic[2] == 2){ $xml .= ''; } } } echo $xml; ?>
which spits out an xml list of every image in the folder gallery.php is included in
<?xml version="1.0"?>
the index page lets you even link to a specific image http://www.mustardlab.com/developer/test/new/?image=sinister.jpg
which is taken care of by some code in the index.php file
" />
all the source code is inhttp://www.mustardlab.com/developer/test/new/gallery.fla
I have to admit though, the visual idea of a photostack has to be credited to Andy from trendwhore.net if any of you are on there, he was also andy on o8. I just tried to make it as fast and seamless as possible
:notworthy amazing
*was that the jmack dog in there too?
jmack dog
?
i think this would be more his breed.

I don't know anything about PHP, but I'd love to look at those PHP files. How can I get at them? (Got the FLA, but can't figure out a way to download the PHP files.)
this is the entire contents of gallery.php
<? $xml = '<?xml version="1.0"?'.'>'; $handle = opendir("."); while ( ($file=readdir($handle)) !== false ) { if ( !is_dir($file) ){ $pic = @getimagesize($file); if($pic != false && $pic[2] == 2){ $xml .= ''; } } } echo $xml; ?>
and the entire code for index.php
Flash Photo Stack " />
sorry, the server will process these files so there's no way of downloading the raw text unless I upload it into a .txt file on the server.
i should just make this easier 
it's fun to clickreally really fast.
nice stuff!
I optimized the code entirely around the ability to click immediately even without all the images loaded and clicking any list size of photos as fast as possible.
sweet!!!11
I had the php converting to xml thing before, but I love the photostack thing (even if the credits go to some guy named andy from some place called o8
)
now make a recursive function that goes through all sub folders etc. and creates a deep nested xml tree :nerd:
:thumbsup:
very nice crafty!
Great!! I'm gonna use that PHP a lot thanks!!
$pic[2] == 2
Maybe a dumb question, but I don't get this part. So pic[0] is width, pic[1] is height, but why pic[2] ==2?
getimagesize($file)> Returns an array with 4 elements. Index 0 contains the width of the image in pixels. Index 1 contains the height. Index 2 is a flag indicating the type of the image: 1 = GIF, 2 = JPG, 3 = PNG, 4 = SWF, 5 = PSD, 6 = BMP, 7 = TIFF(intel byte order), 8 = TIFF(motorola byte order), 9 = JPC, 10 = JP2, 11 = JPX, 12 = JB2, 13 = SWC, 14 = IFF, 15 = WBMP, 16 = XBM. These values correspond to the IMAGETYPE constants that were added in PHP 4.3. Index 3 is a text string with the correct height="yyy" width="xxx" string that can be used directly in an IMG tag.in short it if there is a return and it is of type jpg, do this... runs
But why read for myself when i have all these helpful people to tell me stuff? 
i'm just giving you a hard time. i'm suprised you haven't dug into php yet. it's a blast.
i was considering using this for that 100 lines of AS contest we were going to have for loading data, but I'm assuming that contest is dead?
it's not dead yet, i think we just all got really busy. i keep thinking about it though.

also, we were going to coincide it with the v2 launch.
ok.
btw, in case anyone is wondering what this code does
MovieClip.prototype.addProperty("onLoad", function () { return onLoadHandler[this]; }, function (f) { if (onLoadHandler == undefined) { global.onLoadHandler_ = {}; } onLoadHandler[this] = f; });
I can't remember where I got it from, but it restores the onLoad handler for movieclips when loading jpgs and swfs, very handy when you don't need or want to set up a getBytesLoaded/getBytesTotal loader
I'm assuming everyone is aware that flash wipes out all variables and values of a clip when loading files into that clip, but I guess flash doesn't reset or wipe out properties overridden or added through addProperty.
can you share a simplified example usage?
_root.createEmptyMovieClip("image", 1); image.onLoad = function() { trace("test.jpg has loaded into "+this); }; image.loadMovie("test.jpg");
If you were to run this code above, the onLoad event specificied would never run, the onLoad event would still fire when the loadMovie has finished, but the function attached to that event doesn't exist anymore because all the contents of that movieclip got wiped during the load.
MovieClip.prototype.addProperty("onLoad", function () { return onLoadHandler[this]; }, function (f) { if (onLoadHandler == undefined) { global.onLoadHandler_ = {}; } onLoadHandler[this] = f; });
_root.createEmptyMovieClip("image", 1); image.onLoad = function() { trace("test.jpg has loaded into "+this); }; image.loadMovie("test.jpg");
but by overwriting the onLoad property so that it targets actions stored outside of the movieclip, the function is able to run.
_Originally posted by craftymind _ [B]I can't remember where I got it from, but it restores the onLoad handler for movieclips when loading jpgs and swfs, very handy when you don't need or want to set up a getBytesLoaded/getBytesTotal loader/B]i found one that was very similar in the chatty.figleaf archives.
so will this return a success-false if a failure occurs?
onLoad = function(success){ }
?
MovieClip.onLoad doesn't have any parameters
I am confused.
is this different?
good use of right click, and thumbviews. http://www.andrewberg.com/photobrowser/afpb_flash.html