Loading text into scrolling XML gallery

Hi Everyone,

I found this script that includes a scrolling thumbnail gallery. I only want the thumbnail part and i can make that work but i want to load some text in between each image. Is there a way to this? (My last resort is to turn the text into an image and load it thru xml like the other images but i don’t really want to do this.) Below is the script.

Thanks for your help!

[LEFT][COLOR=#f000f0]/Code for loading XML file. /[/COLOR]
[COLOR=#993300]function[/COLOR] loadXMLCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#f000f0]
/
“xmlNode” is just a faster way of saying “this.firstChild”. /[/COLOR]
[COLOR=#993300]xmlNode[/COLOR] = [COLOR=#993300]this[/COLOR].[COLOR=#993300]firstChild[/COLOR];
image = [COLOR=#000000][[/COLOR][COLOR=#000000]][/COLOR];
head = [COLOR=#000000][[/COLOR][COLOR=#000000]][/COLOR];
description = [COLOR=#000000][[/COLOR][COLOR=#000000]][/COLOR];
thumbnails = [COLOR=#000000][[/COLOR][COLOR=#000000]][/COLOR];
category = [COLOR=#000000][[/COLOR][COLOR=#000000]][/COLOR];
cat = [COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]attributes[/COLOR].[COLOR=#000000]cid[/COLOR]
[COLOR=#f000f0]/ Finds total number of child nodes (images w/captions to be displayed, in this case). /[/COLOR]
total = [COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR].[COLOR=#993300]length[/COLOR];
[COLOR=#f000f0]/ Extracts data from each child node, stopping when the total (defined above) is reached. /[/COLOR]
[COLOR=#993300]for[/COLOR] [COLOR=#000000]([/COLOR]i=[COLOR=#000000]0[/COLOR]; i<total; i++[COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
image[COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR] = [COLOR=#0000ff]“images/”[/COLOR]+[COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]nodeValue[/COLOR];
head[COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR] = [COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]nodeValue[/COLOR];
description[COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR] = [COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]2[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]nodeValue[/COLOR];
category[COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR] = [COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]3[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]nodeValue[/COLOR];
thumbnails[COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR] = [COLOR=#0000ff]“images/th_”[/COLOR]+[COLOR=#993300]xmlNode[/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]1[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR]i[COLOR=#000000]][/COLOR].[COLOR=#993300]childNodes[/COLOR][COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR].[COLOR=#993300]firstChild[/COLOR].[COLOR=#993300]nodeValue[/COLOR];
thumbnails_fnCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR]
firstImageCOLOR=#000000[/COLOR];
cat = [COLOR=#000000]0[/COLOR];
[COLOR=#000000]}[/COLOR] [COLOR=#993300]else[/COLOR] [COLOR=#000000]{[/COLOR]
content = [COLOR=#0000ff]“file not loaded!”[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
xmlData = [COLOR=#993300]new[/COLOR] [COLOR=#993300]XML[/COLOR]COLOR=#000000[/COLOR];
xmlData.[COLOR=#993300]ignoreWhite[/COLOR] = [COLOR=#993300]true[/COLOR];
xmlData.[COLOR=#993300]onLoad[/COLOR] = loadXML;
xmlData.[COLOR=#993300]load[/COLOR]COLOR=#000000[/COLOR];
[COLOR=#f000f0]/////////////////////////////////////[/COLOR]
[COLOR=#f000f0]/ Lets the user scroll through with left and right arrow keys. /[/COLOR]
listen = [COLOR=#993300]new[/COLOR] [COLOR=#993300]Object[/COLOR]COLOR=#000000[/COLOR];
listen.[COLOR=#993300]onKeyDown[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#993300]Key[/COLOR].[COLOR=#993300]getCode[/COLOR]COLOR=#000000[/COLOR] == [COLOR=#993300]Key[/COLOR].[COLOR=#993300]LEFT[/COLOR][COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
prevImageCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR] [COLOR=#993300]else[/COLOR] [COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#993300]Key[/COLOR].[COLOR=#993300]getCode[/COLOR]COLOR=#000000[/COLOR] == [COLOR=#993300]Key[/COLOR].[COLOR=#993300]RIGHT[/COLOR][COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
nextImageCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR];
[COLOR=#993300]Key[/COLOR].[COLOR=#993300]addListener[/COLOR]COLOR=#000000[/COLOR];
[COLOR=#f000f0]/ Note the references to button instances previous_btn and next_btn here./[/COLOR]
previous_btn.[COLOR=#993300]onRelease[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
prevImageCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR];
next_btn.[COLOR=#993300]onRelease[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
nextImageCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR];
[COLOR=#f000f0]/////////////////////////////////////[/COLOR]
[COLOR=#f000f0]/ The movie begins, naturally, at the beginning–in XML, that’s zero! /[/COLOR]
p = [COLOR=#000000]0[/COLOR];
[COLOR=#f000f0]/ Preloader for images. /[/COLOR]
[COLOR=#993300]this[/COLOR].[COLOR=#993300]onEnterFrame[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
filesize = picture.[COLOR=#993300]getBytesTotal[/COLOR]COLOR=#000000[/COLOR];
[COLOR=#993300]loaded[/COLOR] = picture.[COLOR=#993300]getBytesLoaded[/COLOR]COLOR=#000000[/COLOR];
preloader.[COLOR=#993300]_visible[/COLOR] = [COLOR=#993300]true[/COLOR];
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#993300]loaded[/COLOR] != filesize[COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
preloader.[COLOR=#993300]_visible[/COLOR] = [COLOR=#993300]true[/COLOR];
[COLOR=#000000]}[/COLOR] [COLOR=#993300]else[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#f000f0]/ Makes preloader invisible once the image starts to fade in. /[/COLOR]
preloader.[COLOR=#993300]_visible[/COLOR] = [COLOR=#993300]false[/COLOR];
[COLOR=#f000f0]/ Fade in the image. (If the alpha is under 100, add 10.) /[/COLOR]
[COLOR=#993300]if[/COLOR] COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
picture.[COLOR=#993300]_alpha[/COLOR] += [COLOR=#000000]10[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR];
[COLOR=#f000f0]/ Load & display the next image. It cleverly calculates whether you are at the end of the
images or not. If you are, the script doesn’t run./[/COLOR]
[COLOR=#993300]function[/COLOR] nextImageCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#f000f0]/ If it’s less than the total (the last image), let’s go ahead and load the next image. /[/COLOR]
[COLOR=#993300]if[/COLOR] COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
p++;
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#993300]loaded[/COLOR] == filesize[COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#f000f0]/ If it is loaded, set alpha to zero, so that the preloader can fade it in! /[/COLOR]
picture.[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]0[/COLOR];
[COLOR=#f000f0]/ Put the image where it is supposed to go. /[/COLOR]
picture.[COLOR=#993300]loadMovie[/COLOR][COLOR=#000000]([/COLOR]image[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR], [COLOR=#000000]1[/COLOR][COLOR=#000000])[/COLOR];
[COLOR=#f000f0]/ Load description into text box “desc_txt” /[/COLOR]
desc_txt.[COLOR=#993300]text[/COLOR] = description[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR];
head_txt.[COLOR=#993300]text[/COLOR] = head[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR];
[COLOR=#f000f0]/ Activates the function down below, telling you what number picture you’re viewing. /[/COLOR]
picture_numCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
[COLOR=#f000f0]/ Basically the same as nextImage(), but backwards. Fading and image/text insertion is the same. /[/COLOR]
[COLOR=#993300]function[/COLOR] prevImageCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
p–;
picture.[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]0[/COLOR];
picture.[COLOR=#993300]loadMovie[/COLOR][COLOR=#000000]([/COLOR]image[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR], [COLOR=#000000]1[/COLOR][COLOR=#000000])[/COLOR];
desc_txt.[COLOR=#993300]text[/COLOR] = description[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR];
head_txt.[COLOR=#993300]text[/COLOR] = head[COLOR=#000000][[/COLOR]p[COLOR=#000000]][/COLOR];
picture_numCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
[COLOR=#f000f0]/ Automatically show the first image when the movie is loaded, fade-in and all. /[/COLOR]
[COLOR=#993300]function[/COLOR] firstImageCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR][COLOR=#993300]loaded[/COLOR] == filesize[COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
picture.[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]0[/COLOR];
[COLOR=#f000f0]/ Use image[0] instead of image[p] since this only applies to the first image. /[/COLOR]
picture.[COLOR=#993300]loadMovie[/COLOR][COLOR=#000000]([/COLOR]image[COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR], [COLOR=#000000]1[/COLOR][COLOR=#000000])[/COLOR];
desc_txt.[COLOR=#993300]text[/COLOR] = description[COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR];
head_txt.[COLOR=#993300]text[/COLOR] = head[COLOR=#000000][[/COLOR][COLOR=#000000]0[/COLOR][COLOR=#000000]][/COLOR];
picture_numCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR]
[COLOR=#f000f0]/ Thumbnail list. /[/COLOR]
[COLOR=#993300]function[/COLOR] thumbnails_fnCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
thumbnail_mc.[COLOR=#993300]createEmptyMovieClip[/COLOR][COLOR=#000000]([/COLOR][COLOR=#0000ff]“t”[/COLOR]+k, thumbnail_mc.[COLOR=#993300]getNextHighestDepth[/COLOR]COLOR=#000000[/COLOR][COLOR=#000000])[/COLOR];
tlistener = [COLOR=#993300]new[/COLOR] [COLOR=#993300]Object[/COLOR]COLOR=#000000[/COLOR];
tlistener.[COLOR=#993300]onLoadInit[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
target_mc.[COLOR=#993300]_x[/COLOR] = hit_left.[COLOR=#993300]_x[/COLOR]+COLOR=#000000[/COLOR]k;
target_mc.[COLOR=#000000]pictureValue[/COLOR] = k;
target_mc.[COLOR=#993300]onRelease[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
p = [COLOR=#993300]this[/COLOR].[COLOR=#000000]pictureValue[/COLOR]-[COLOR=#000000]1[/COLOR];
nextImageCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR];
target_mc.[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]50[/COLOR];
target_mc.[COLOR=#993300]onRollOver[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]this[/COLOR].[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]100[/COLOR];
thumbNailScrollerCOLOR=#000000[/COLOR];
[COLOR=#000000]}[/COLOR];
target_mc.[COLOR=#993300]onRollOut[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]this[/COLOR].[COLOR=#993300]_alpha[/COLOR] = [COLOR=#000000]50[/COLOR];
[COLOR=#000000]}[/COLOR];
[COLOR=#000000]}[/COLOR];
image_mcl = [COLOR=#993300]new[/COLOR] [COLOR=#993300]MovieClipLoader[/COLOR]COLOR=#000000[/COLOR];
image_mcl.[COLOR=#993300]addListener[/COLOR]COLOR=#000000[/COLOR];
image_mcl.[COLOR=#993300]loadClip[/COLOR][COLOR=#000000]([/COLOR]thumbnails[COLOR=#000000][[/COLOR]k[COLOR=#000000]][/COLOR], [COLOR=#0000ff]“thumbnail_mc.t”[/COLOR]+k[COLOR=#000000])[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#993300]function[/COLOR] thumbNailScrollerCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#f000f0]
// thumbnail code![/COLOR]
[COLOR=#993300]this[/COLOR].[COLOR=#993300]createEmptyMovieClip[/COLOR][COLOR=#000000]([/COLOR][COLOR=#0000ff]“tscroller”[/COLOR], [COLOR=#000000]1000[/COLOR][COLOR=#000000])[/COLOR];
scroll_speed = [COLOR=#000000]10[/COLOR];
tscroller.[COLOR=#993300]onEnterFrame[/COLOR] = [COLOR=#993300]function[/COLOR]COLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR]COLOR=#000000[/COLOR] && COLOR=#000000[/COLOR][COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR]COLOR=#000000[/COLOR] && COLOR=#000000[/COLOR][COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
thumbnail_mc.[COLOR=#993300]_x[/COLOR] -= scroll_speed;
[COLOR=#000000]}[/COLOR] [COLOR=#993300]else[/COLOR] [COLOR=#993300]if[/COLOR] [COLOR=#000000]([/COLOR]COLOR=#000000[/COLOR] && COLOR=#000000[/COLOR][COLOR=#000000])[/COLOR] [COLOR=#000000]{[/COLOR]
thumbnail_mc.[COLOR=#993300]_x[/COLOR] += scroll_speed;
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR] [COLOR=#993300]else[/COLOR] [COLOR=#000000]{[/COLOR]
[COLOR=#993300]delete[/COLOR] tscroller.[COLOR=#993300]onEnterFrame[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#000000]}[/COLOR];
[COLOR=#000000]}[/COLOR]
[COLOR=#f000f0]
/* Displays current position and total number of pictures. /[/COLOR]
[COLOR=#993300]function[/COLOR] picture_numCOLOR=#000000[/COLOR] [COLOR=#000000]{[/COLOR]
current_pos = p+[COLOR=#000000]1[/COLOR];
pos_txt.[COLOR=#993300]text[/COLOR] = current_pos+[COLOR=#0000ff]" / "[/COLOR]+total;
[COLOR=#000000]}[/COLOR]
[/LEFT]