Hi again.
I´m almost there. This is acutually my first flash project, so i´m a newbie here.
Here is what i´ve done:
I send the the variables to a phpfile. like this:
<a href="file.php?image=an1.jpg&description=my first image">Image 32</a>
The file.php:
<?php
$image = $_GET['image'];
$description = $_GET['description'];
?>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="
http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,79,0" width="550" height="400">
<param name="movie" value="file.swf?<?php echo ("image=$image&description=$description"); ?>" />
<param name="quality" value="high" />
<embed src="file.swf?<?php echo ("image=$image&description=$description"); ?>" quality="high" pluginspage="
http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="550" height="400"></embed>
</object>
and the code in flash:
infoField._visible = true;
startLoading (+ image);
function startLoading(whichImage) {
loadMovie(whichImage, "imageLoader");
_root.onEnterFrame = function() {
infoLoaded = imageLoader.getBytesLoaded();
infoTotal = imageLoader.getBytesTotal();
percentage = Math.floor(infoLoaded/infoTotal*100);
infoField.text = percentage+"%";
if (percentage>=100) {
delete this.onEnterFrame;
infoField._visible = false;
}
};
}
Comments.text = "text here:\n" + description;
This actually works for mee. I get a image and description of the image depending on wich image i choose i´m my php gallery. However yhe preloader doesn´t work. Any idea why? what´s missing in the preloader?