Results 1 to 5 of 5

Thread: DD Tab menu - return to current tab

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

    Default DD Tab menu - return to current tab

    1) Script Title: DD Tab menu

    2) Script URL (on DD):
    http://www.dynamicdrive.com/dynamicindex1/ddtabmenu.htm

    3) Describe problem:
    I have modified this script so that when hovering over one of the main tabs, another layer of links (submenu) is listed horizontally below the main tabs. Once the submenu is shown for a hovered main tab, it stays until another main tab is hovered.

    Now what I want to do is this: when the user moves his mouse over to another tab, I want the hovered main tab and submenu to show and when the mouse is not hovering over any tab or submenu, then it will revert to the current tab and submenu.

    Hope that made sense

  2. #2
    Join Date
    Jun 2007
    Posts
    543
    Thanks
    3
    Thanked 78 Times in 78 Posts
    Blog Entries
    1

    Default

    Please show the modified script so we can help you to a better extent.
    [Jasme Library (Javascript Motion Effects)] My Site
    /\/\@§†ê® §©®¡þ† /\/\@|{ê®
    There are 10 kinds of people in the world, those that understand binary and those that don't.

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

    Default

    The script is still the same, I just changed this part of Example 4:

    Code:
    <DIV class="tabcontainer">
    
    <div id="sc1" class="tabcontent">
    Sub contents here
    </div>
    
    <div id="sc2" class="tabcontent">
    Sub contents here
    </div>
    
    <div id="sc3" class="tabcontent">
    Sub contents here
    </div>
    
    </DIV>
    Everything else (javascript, css) is the default code.

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

    Default

    Try the below modified ddtabmenu.js, and refer to the variable at the top:

    Code:
    snap2original: [true, 500], ////Should tab revert back to default selected when mouse moves out of menu? ([true/false, miliseconds_b4_revert]

  5. The Following User Says Thank You to ddadmin For This Useful Post:

    roystik (02-23-2008)

  6. #5
    Join Date
    Jul 2007
    Posts
    17
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default

    Thanks for the js, will try it and let you know how it works out.

    UPDATE: It works! Awesome! A great big thank you to ddadmin is in order.
    Last edited by roystik; 02-25-2008 at 02:07 AM.

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
  •