Hello everyone! i’m pretty new to XML with Flash, so here goes. I am currently using this tut http://www.kirupa.com/developer/mx2004/xml_flash_photogallery.htm
to build the portfolio section of my site. This tut is great, but the problem that i am having is,instead of using previous and next buttons, I would rather have as many buttons as possible, to represent different images that are listed in the xml code. How would I tweak this code to perform this action?
Thank you all,
SpyGuy
here is the code
p = 0;
this.onEnterFrame = function() {
filesize = picture.getBytesTotal();
loaded = picture.getBytesLoaded();
preloader._visible = true;
if (loaded != filesize) {
preloader.preload_bar._xscale = 100*loaded/filesize;
} else {
preloader._visible = false;
if (picture._alpha<100) {
picture._alpha += 10;
}
}
};
function nextImage() {
if (p<(total-1)) {
p++;
if (loaded == filesize) {
picture._alpha = 0;
picture.loadMovie(image[p], 1);
desc_txt.text = description[p];
picture_num();
}
}
}
function prevImage() {
if (p>0) {
p--;
picture._alpha = 0;
picture.loadMovie(image[p], 1);
desc_txt.text = description[p];
picture_num();
}
}
function firstImage() {
if (loaded == filesize) {
picture._alpha = 0;
picture.loadMovie(image[0], 1);
desc_txt.text = description[0];
picture_num();
}
}
****[U][FONT=Arial Black][SIZE=2]