Results 1 to 2 of 2

Thread: flash image menu

  1. #1
    Join Date
    Feb 2008
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question flash image menu

    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");

  2. #2
    Join Date
    Aug 2005
    Location
    Other Side of My Monitor
    Posts
    3,494
    Thanks
    5
    Thanked 105 Times in 104 Posts
    Blog Entries
    1

    Default

    It's actually getting PHP from the file, not html which you won't get by decompiling the movie. (Sucks when they can tell, huh?)

    Your best bet is to figure out exactly what you want, loading via XML, PHP or plain txt. Then finding a good tutorial or open source (type) .fla that you can see the entire code and know how it works.

    Flashmatics has a few such players to learn from/use.
    {CWoT - Riddle } {Freelance Copywriter} {Learn to Write}
    Follow Me on Twitter: @InkingHubris
    PHP Code:
    $result mysql_query("SELECT finger FROM hand WHERE id=3");
    echo 
    $result

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •