Search  

MYSECTIONEDMENU (XML)

HomeBrowse CategoriesFlashMenus & ButtonsVertical MenusmySectionedMenu (xml)

May5th, 2008 : File was re-uploaded. Fixed all bugs reported previously

An easy to manage, xml-based, iPod-ish tree menu..

Features:

  • XML BASED TREE MENU
  • HAVE AS MUCH AS 5 LEVELS DEEP FOR EACH MAIN MENU !
    MORE LEVELS CAN BE ADDED UPON REQUEST
  • AUTO SCROLL FOR HEIGHT MORE THAN DEFAULT HEIGHT
  • ROLL MOUSE WHEEL BACKWARDS TO COLLAPSE SUB SECTIONS
  • CHOOSE TO RUN A FUNCTION OR LAUNCH AN EXTERNAL LINK *
  • MOTION BLUR EFFECT *
  • ADJUST WIDTH /HEIGHT/SPEED/UPPERCASE/MAX CHARACTER ETC *
  • ALL STORED WITHIN ONE MAIN MOVIECLIP FOR EASY IMPORTING
  • ONLY RELATED MENU ARE CREATED WHEN CALLED , REST ARE DESTROYED
  • ALSO USING FUSEKIT FOR SLICK TWEENING
Note:You will need FuseKit installed to get this file to work, it is very easy to install, dont worry :) you can get it for free here



Related file(s):

myScrollMenu-vertical (xml)


myScrollMenu-Horizontal (xml)

AATW - added along the way

  • Using chars like ó ú é etc… – 23 Feb 08 – on line frame 1 in ‘mysectionedMenu’ in library add at the beginning
    System.useCodepage = true;
    Next, get into ‘menu’ movieClip, doubleClick the text, select the text box, see properties panel, click the embed button, you will see uppercase, lowercase, numeric & punctuation are selected, you can select more by ctrl+click the respective additional font packages which you need.

  • Home btn to reset menu – 23 Feb 08 – Create a btn on stage, give it an instance name: “homeBtn”. on frame 10 in ‘mySectionedMenu’ add script below at the end:
    homeBtn.onRelease = function(){
        if(root.curLevel != undefined){
            root.curLevel = undefined;
            getSubs();
        }
    }
    
  • Clicked menu stay highlighted – 23 Feb 08 – Pls add following scripts in ‘mySectionMenu’ movieClip found in library. On Frame 10:
    1. for ‘rollin’ & ‘rollout’ functions put a if statement in it:
      rollin = function () {
          if(this.no != root.hit){
              this.gotoAndPlay("in");
          }
      };
      rollout = function () {
          if(this.no != root.hit){
              this.gotoAndPlay("out");
          }
      };
      
    2. for ‘releaseIt’ & ‘getSubs’ functions put this at the beginning:
      var m:MovieClip = mainHol["lev"+root.curLevel].levHol["m"+root.hit];
      if(this.no != root.hit){
          m.gotoAndPlay("out");
      }
      root.hit = this.no;
      
  • Execute a function with parameters + LoadMovie – 25th Oct 07
    1. a param value needs to be sent via xml, it cant be someFunction(param) as it will execute even before clicking any buttons.. so do it like this instead:
      <sub title="Experimental" url="someFunction" params="movie1.swf, something"  target="" type="function"></sub>
      
    2. next get into ‘mySectionedMenu’ mc from library, on frame 1’s actionscript on line 34, 46, 59, 72 & 85. you will need to store the params value into the array.. add this at end of the array like this:
      line 34:
      ... , rootNode[i].attributes.params]);
      line 46:
      ... , rootNode2[ii].attributes.params]);
      line 59:
      ... , rootNode3[iii].attributes.params]);
      line 72:
      ... , rootNode4[iv].attributes.params]);
      line 85:
      ... , rootNode5[v].attributes.params]);
      
    3. next on frame 10’s actionscript locate releaseIt function and

      change this:

      var f:Function = _root[menu[this.no][2]];
      trace("RUN FUNCTION: "+menu[this.no][2]);
      f();
      
      to this:
      var f:Function = _root[menu[this.no][2]];
      var p:String = menu[this.no][6];
      var parameters:Array = p.split(", ");
      trace("RUN FUNCTION: "+menu[this.no][2]);
      f(parameters[0], parameters[1]);
      
    4. lastly, edit the ‘someFunction’ function on the root

      change this:

      someFunction = function(){
          trace("Hi im from a function!")
      }
      
      to this:
      someFunction = function(p1:String, p2:String){
          //p1 will give the value "movie1.swf" as add in the xml
          //p2 will give the value "something" as add in the xml
          trace("> "+p1);
          trace("> "+p2);
          //load movie function:
          //make sure on _root there is an empty movieclip
          //with the name movieHolder
          _root.movieHolder.loadMovie(p1);
      }
      


Posted about 1 year ago

@pattleger
To make changes to the size of the font, open up the library panel in flash (CTRL+L).. double click ‘menu’ movieclip, select the text box, see the properties panel to text options like size color etc. do the same for the ‘back’ movieclip, next publish the movie to see the changes.

Posted 2 months ago

Hi Encryptme, great menu, thanks :)

My problem is that when exporting the menu and testing it by itself (menu.swf), it works fine and loads in the xml like it should.

When put into my test page, with the swfobject.js included and the menu.swf referenced, the swf appears (as I changed the bg colour to test), but it’s blank, as if the xml isn’t loading. But the xml is in the same directory as the swf.

Weird. Any advice appreciated.

Posted about 1 month ago

@Storm
are you saying its working locally and when uploaded on a server, its not appearing ? it could be that you need to use full server path to the xml file.

Posted about 1 month ago

The absolute path didn’t work in this case, though with a normal site I`d say it would.

Found the solution though: copied the menu.xml into a folder, then tested the site again (repeat x times). It worked when I copied the xml into the root folder.

The site I`m working on is a mixture of php/html and .tpl (templates used in the ‘Smarty’ engine). Anyway, the header.tpl where the swfobject code is (to load the flash), is part of what gets made into index.html by the php from various files. So index.html is in the root, and that’s where the swf thinks it is too (even though it’s really a few levels down), because that’s where the swfobject2 code calls it into action, and that’s where it wants the xml.

Posted about 1 month ago

how to add function and link to first level menu, (not just sub menu)

Posted about 1 month ago

hey heyyy encryptme… great menu,

im looking to purchase this menu in the next few hours.. but i have a quick question question..

is there anyway i can add more then 5 levels using my flash mx…?

thanx..

Posted about 1 month ago

encryptme, great menu man,

i tried your menu, it really is great, got it workign and all..

one question please.. there are green lines that seem to come up on screen when moving between the menu categories… any way to fix that..??

Posted about 1 month ago

@nayyer
thanks for the purchase, I’m not quite sure which green lines you are refering to, can you please email me with a screen capture of the issue? Thanks.

Posted about 1 month ago

encryptme, apologies for the premature mesg’s…. the green lines were actually just a cause of exporting the swf and playing the generated file from flash …

when closing the swf and relaunching it using the player there were no green lines…

great file once again, easy to alter colors and fonts… highly recommended…!!

encryptme, one last question i promise…

in your other menu (myScrollMenu-Horizontal (xml)) there is a trace box on screen that shows the function output when pressed…

how do i place a similar box on stage using this menu… ? thanx much..

Posted about 1 month ago

Hi,

I’m using a similar sliding menu to this at the moment that is xml based. Could I ask if it is possible with this menu to to set a parameter so that it displays the menu from a level down ie sub menu?

Therefore when the user selected a page from the menu in a sub section the html page would load and rather than the menu reloading and starting from the top level it would display a sub section based on the parameter that I had passed in.

Regards Dan

Posted 21 days ago

@Cooltide
this version currently does not support that feature, its been requested before, so ill make sure the next version comes with this feature. cheers.

Posted 19 days ago