Results 1 to 2 of 2

Thread: Default tab for Tabs Menu?

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

    Default Default tab for Tabs Menu?

    1) Script Title: Tabs Menu (mouseover)

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

    3) Describe problem: It is not really a problem. I am adapting this nift little bit of code for my wiki. I would , however, like to have a default active tab. So rather than nothing appearing under the links (tabs) I would like the links that appear on hovering over the 'Javascript Kit' tab to be already there when I open my page. Can someone giving me some suggestions. I don't a lot of javascript but I'm not bad at adapting code if given some direction.

    Hopefully you can help. Cheers,

    Johnny

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

    Default

    Try adding the line in red to the existing line inside the script below:

    Code:
    var menuobj=document.getElementById? document.getElementById("describe") : document.all? document.all.describe : document.layers? document.dep1.document.dep2 : ""
    
    setTimeout("menuobj.innerHTML=submenu[0]", 500)
    submenu[0] would correspond to the menu contents variable you wish to be shown by default.

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

    Seanmac30 (02-25-2008)

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
  •