i wanna create a flash menu with external image and text
something like this : http://indiafm.com/
all i know about this menu is , it's taking data from a external .html file
and the action used for that is
// Action script...
// [onClipEvent of sprite 30 in frame 6]
onClipEvent (load)
{
this.stop();
}
// [Action in Frame 1]
this.onEnterFrame = function ()
{
if (_root.getBytesLoaded == _root.getBytesTotal)
{
delete this.onEnterFrame;
nextFrame ();
}
else
{
stop ();
} // end else if
};
Stage.showMenu = false;
// [Action in Frame 2]
dataload = new LoadVars();
dataload.sendAndLoad("http://www.bollywoodhungama.com/topbanner/promo.html", dataload, "GET");
dataload.onLoad = function (success)
{
if (success)
{
if (dataload.done eq "ok")
{
promodata = dataload.promodata;
nextFrame ();
} // end if
}
else
{
dataload.sendAndLoad("http://www.bollywoodhungama.com/topbanner/promo.html", dataload, "GET");
} // end else if
};
stop ();
// [Action in Frame 3]
tempPromo = promodata.split("|");
imgPath = [];
imgTitle = [];
mainTitle = [];
info = [];
author = [];
targ = [];
urlPath = [];
for (i = 0; i < tempPromo.length; i++)
{
a = tempPromo[i].split("#");
imgPath[i] = a[0];
imgTitle[i] = a[1];
mainTitle[i] = a[2];
info[i] = a[3];
author[i] = a[4];
targ[i] = a[5];
urlPath[i] = a[6];
} // end of for
gotoAndStop("home");
// [Action in Frame 4]
function imageLoad()
{
loadMovie(imgPath[cnt], "imgHold");
this.onEnterFrame = function ()
{
if (imgHold.getBytesLoaded() == imgHold.getBytesTotal() && imgHold.getBytesLoaded() > 4)
{
if (cnt < 5)
{
++cnt;
imageLoad();
}
else
{
delete this.onEnterFrame;
gotoAndPlay("home");
} // end if
} // end else if
};
} // End of the function
cnt = 0;
imageLoad();
stop ();
// [Action in Frame 6]
function nextTab()
{
info_MC.gotoAndPlay("fadeOut");
eval("tabs." + tabs.storePan).tabPanel.gotoAndStop(1);
eval("tabs.panel" + cnt).tabPanel.gotoAndStop(2);
tabs.storePan = eval("_root.tabs.panel" + cnt);
} // End of the function
var cnt = 0;
// [Action in Frame 7]
function executeCallback()
{
if (count >= maxCount)
{
if (cnt < 6)
{
++cnt;
}
else
{
cnt = 0;
} // end else if
nextTab();
image_MC.alphaRed();
clearInterval(intervalId);
nextFrame ();
} // end if
++count;
} // End of the function
var intervalId;
var count = 0;
var maxCount = 250;
var duration = 20;
intervalId = setInterval(this, "executeCallback", duration);
stop ();
// [Action in Frame 8]
stop ();
// [Action in Frame 9]
gotoAndStop("timeOut");





Bookmarks