PDA

View Full Version : Styling Tab Content Script



jasonk
01-29-2008, 11:29 PM
Tab Content Script (v 2.0)

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

Describe problem: I am trying to separately style the tab and content sop the tab stays highlighted for the current content but so the content doesn't have to have a colored background.
http://dev.keyfax.com/xfactor/partners.php#
I can't seem to seperate the two styles. Any ideas?

ddadmin
01-30-2008, 01:50 AM
You're actually using the older version of this script (Tab Content script I). The current version is v 2.0. For the older version (one you're using now), you can limit the theme color change for the selected item so only the selected tab itself is affected in terms of background color change, and not the selected tab's content DIV. Inside the script, change the line:


aobject.style.backgroundColor=document.getElementById("tabcontentcontainer").style.backgroundColor=themecolor

To:


aobject.style.backgroundColor=themecolor

That's about the extent in which you can style/unstyle the selected tab's content DIV with this script, however.