Results 1 to 3 of 3

Thread: Issue with link in chromemenu main item with dropdown feature

  1. #1
    Join Date
    Jan 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Issue with link in chromemenu main item with dropdown feature

    Chromemenu
    http://www.dynamicdrive.com/dynamici...rome/index.htm

    Hi,

    I am trying to incorperate chromemenu in a website. I have put the building of the menu structure into a js file, so that it can easily be changed on one position in the website, and added it into several htm pages within the site.

    When I try to add a link to the main item AND use a reference to a dropdown on that main item, the link isn't followed when clicked on:

    Code:
    document.write("<div class='chromestyle' id='chromemenu'>")
    document.write("<ul>")
    document.write("<li><a href='default.htm' rel='dropmenu1'>Home</a></li>")
    document.write("</ul>")
    document.write("</div>")
    
    document.write("<div id='dropmenu1' class='dropmenudiv' style='width: 170px;'>")
    document.write("<a href='welkom_historie.htm'>Historie</a>")
    document.write("<a href='welkom_organogram.htm'>Organogram</a>")
    document.write("</div>")
    When I remove the rel='dropmenu1' it does work:
    Code:
    document.write("<div class='chromestyle' id='chromemenu'>")
    document.write("<ul>")
    document.write("<li><a href='default.htm'>Home</a></li>")
    document.write("</ul>")
    document.write("</div>")
    This is tested in IE7.

    Is there a way to work around this behaviour?

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    If I understood you correctly, inside the .js file of the menu, just change the line near the top:

    Code:
    disablemenuclick: false, //when user clicks on a menu item with a drop down menu, disable menu item's link?
    to false.

  3. #3
    Join Date
    Jan 2007
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    you understood me correctly! this does the trick... this reminds me to look at the code the next time, especially when it is commented like this. :-)

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
  •