Problem, need help.

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bigbuddha

    Problem, need help.

    I have found this nice menu form my website www.folkspot.be
    But it has a usability problem.
    When i click "crew" for example, the submenu "crew" opens and i have to
    click the submenu to get to the page. As you notice, this is a click to
    many. As you can see this is the case in several items. Some do have
    subitems and work fine. I'm to much of a newbee in javascript to figure
    this out.

    Can someone please help me fix this problem?

    thanks.

    --
    Bigbuddha



  • BigRed

    #2
    Re: Problem, need help.

    Open the SLIDING_MENU.JS file and look for the function
    "write_menu ()". Scroll down until you see the variable "csmc = 0;".
    The next line should be a command starting out like this:

    document.write( "<div class='men' style='top.....


    Highlight and COPY the code below. Find that
    "document.write ("<div......"); " command as stated above and copy over
    the ENTIRE line with the new code.


    //START YOUR COPY HERE
    if (la[2] != "")
    {
    document.write( "<a href='"+la[2]+"'
    style='text-decoration:none ;'");
    if (la[3] != "") document.write( " target='" + la[3] + "' ");
    }

    document.write( "<div class='menu'
    style='top:"+mn +";height:"+hei ght+"' id='down"+smc+" '
    onclick='prepar e("+smc+","+mni +")'>&nbsp;" + la[1] + "</div>");

    if (la[2] != "") { document.write( "</a>"); }
    //END YOUR COPY HERE



    You're done!!! All this does is wrap that main menu item with a <A>
    tag IF you add a link in your LINK array. Here are your new choices
    when adding a link. Choice 3 is what you wanted....

    //MAIN MENU ITEM - SUB-MENU LINK.
    Link[0] = "0|Home|";
    Link[1] = "1|Home|index.h tml|_top";

    //MAIN MENU ITEM - NO LINK
    Link[0] = "0|Home|";

    //MAIN MENU ITEM - LINKED WITHOUT SUB-MENU
    Link[0] = "0|Home|home.ht ml|_top";

    Comment

    • Bigbuddha

      #3
      Re: Problem, need help.

      BigRed wrote:
      [color=blue]
      > Open the SLIDING_MENU.JS file and look for the function
      > "write_menu ()". Scroll down until you see the variable "csmc = 0;".
      > The next line should be a command starting out like this:
      >
      > document.write( "<div class='men' style='top.....
      >
      >
      > Highlight and COPY the code below. Find that
      > "document.write ("<div......"); " command as stated above and copy over
      > the ENTIRE line with the new code.
      >
      >
      > //START YOUR COPY HERE
      > if (la[2] != "")
      > {
      > document.write( "<a href='"+la[2]+"'
      > style='text-decoration:none ;'");
      > if (la[3] != "") document.write( " target='" + la[3] + "' ");
      > }
      >
      > document.write( "<div class='menu'
      > style='top:"+mn +";height:"+hei ght+"' id='down"+smc+" '
      > onclick='prepar e("+smc+","+mni +")'>&nbsp;" + la[1] + "</div>");
      >
      > if (la[2] != "") { document.write( "</a>"); }
      > //END YOUR COPY HERE
      >
      >
      >
      > You're done!!! All this does is wrap that main menu item with a <A>
      > tag IF you add a link in your LINK array. Here are your new choices
      > when adding a link. Choice 3 is what you wanted....
      >
      > //MAIN MENU ITEM - SUB-MENU LINK.
      > Link[0] = "0|Home|";
      > Link[1] = "1|Home|index.h tml|_top";
      >
      > //MAIN MENU ITEM - NO LINK
      > Link[0] = "0|Home|";
      >
      > //MAIN MENU ITEM - LINKED WITHOUT SUB-MENU
      > Link[0] = "0|Home|home.ht ml|_top";[/color]

      I'll give it a try tonight

      thansk!

      --
      Bigbuddha


      Comment

      Working...