Hi to all,
I am new in Kirupa forum.
I am using below script for xml thumnail gallery. Displaying of images is coming fine, I need to disply each title when roll over the image. That added in code but it’s not working. Iam little bit confused.
Can any one help please.
function loadPhotoXML(filename)
{
photoXML.ignoreWhite = true;
photoXML.load(filename);
photoXML.onLoad = function (success)
{
if (success)
{
photoNumber = 0;
rootNode = this.firstChild;
totalPhotos = rootNode.childNodes.length;
var __reg2 = 0;
while (__reg2 < totalPhotos * 2)
{
if (__reg2 < totalPhotos)
{
thumbnails[__reg2] = rootNode.childNodes[__reg2].childNodes[0].firstChild.nodeValue;
link[__reg2] = rootNode.childNodes[__reg2].childNodes[1].firstChild.nodeValue;
titleText[__reg2] = rootNode.childNodes[__reg2].childNodes[2].firstChild.nodeValue;
}
else
{
thumbnails[__reg2] = rootNode.childNodes[__reg2 - totalPhotos].childNodes[0].firstChild.nodeValue;
link[__reg2] = rootNode.childNodes[__reg2 - totalPhotos].childNodes[1].firstChild.nodeValue;
titleText[__reg2] = rootNode.childNodes[__reg2 - totalPhotos].childNodes[2].firstChild.nodeValue;
}
thumbnailsLoad(__reg2);
++__reg2;
}
checkProgressLoad(0);
//caption.text = titleText[0];
}
}
;
}
function thumbnailsLoad(k)
{
thumbnailsWidth = mclThumbnails._width;
mclThumbnails.attachMovie("scrollSymbol", "mcl" + k, mclThumbnails.getNextHighestDepth(), {_x: mclWidth * k});
var __reg4 = new MovieClipLoader();
var __reg3 = new Object();
__reg3.onLoadInit = function (mclTarget)
{
mclTarget._alpha = 100;
var __reg4 = undefined;
var __reg5 = undefined;
__reg4 = mclTarget._x;
__reg5 = mclTarget._y;
mclTarget.onRollOver = function ()
{
_root.is_move = false;
this._alpha = 80;
this._parent._parent.gotoAndPlay("show");
_root.mclThumbnails.mclTarget.caption.text = titleText[k];
trace(caption.text);
}
;
mclTarget.onRollOut = function ()
{
_root.is_move = true;
this._alpha = 95;
this._parent._parent.gotoAndPlay("hide");
}
;
mclTarget.onDragOut = function ()
{
_root.is_move = true;
this._alpha = 95;
this._parent._parent.gotoAndPlay("hide");
}
;
Thanks.