Results 1 to 2 of 2

Thread: Linking in Tab Content Script (V2.0)

  1. #1
    Join Date
    Aug 2005
    Posts
    20
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Linking in Tab Content Script (V2.0)

    Tab content script (v2.0)

    http://www.dynamicdrive.com/dynamici...tabcontent.htm

    I need to link from content in one tab to another tab. For the life of me I can't make this happen. I've tried two methods:

    1. <a href="#" rel="country6">More information</a> ie. using the same link syntax as written at top of the script for tab navigation.

    2. <a href="javascript:countrytabs.expandit('country6')">`More information</a> using the javascript method suggested on the script page above.

    Both show up as underlined blue links, but the first just anchors to the top of the page, and the second (javascript method) does absolutely nothing at all.

    Anyone any idea how to make these work? I repeat, this is for a link from within one tab, to another tab.

    Many thanks
    Hugh

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

    Default

    The syntax for an arbitrary link that selects a particular tab would be the #2 one above (not the first), for example:

    Code:
    <a href="javascript:myflowers.expandit(1)">Select 2nd Tab</a>
    "myflowers" should be changed to the variable representing your Tabs Content instance, and 1 in this case means the 2nd tab (0=1st, 2=3rd etc).
    DD Admin

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
  •