| javascript_components

# Class: Bs_TabSet Source Location: /components/tabset/Bs_TabSet.class.js.php
### Class Overview
A TabSet Component. #### Author(s): andrej at blueshoes dot org #### Copyright: blueshoes.org | ### Variables Bs_TabSet:: $tabs $_constructor $_outerElmId | ### Methods addTab draw fireOnTabSelect getActiveTab onTabSelect render switchTo
### Inherited Variables | ### Inherited Methods
### Class Details [line 30] A TabSet Component. Features: IE6 and NS(Mozilla7) compliant. How to use: Have a look at the example (see example link below) Create a function in the HTML-header called init(). Place the javascript code that instanciates and inits this component into init(). Place an 'onLoad' in your body-tag: e.g. <body onLoad="init();"> In the HTML body: Place a div- or span-tag with an unique ID where you want the component to be. How it works: [After instanciating and initializing the object]. Call the draw() method. This will search the HTML code for a tag with the given id and insert HTML- and JS- code dynamically (using DOM) to display the component and handle it. #### Tags:
copyright: | blueshoes.org
author: | andrej at blueshoes dot org
example: | example not found
[ Top ] ### Class Variables #### = arguments [line 33]
Type: | mixed
[ Top ] #### $tabs = array() [line 61]
Type: | mixed
[ Top ] #### $_constructor = [line 243]
Type: | mixed
[ Top ] #### $_outerElmId = (a.length>1) ? a[1] : a[0] [line 34]
Type: | mixed
[ Top ] ### Class Methods ### method addTab [line 95]
`void addTab( string caption, element container)`
#### Tags:
access: | public
#### Parameters:
string | caption | caption
element | container | container
[ Top ] ### method draw [line 136]
`void draw( )`
#### Tags:
access: | public
[ Top ] ### method fireOnTabSelect [line 218]
`true fireOnTabSelect( string 0)`
fires the onTabSelect for the trigger specified. #### Tags:
see: | Bs_TabSet::onTabSelect()
#### Parameters:
string | 0 | trigger
[ Top ] ### method getActiveTab [line 187]
`void getActiveTab( )`
Get the currently active tab as object Note: This is just the one *currently visible* tab of the tabset. [ Top ] ### method onTabSelect [line 207]
`void onTabSelect( mixed yourEvent)`
attaches onTabSelect-event. examples: myObj.onTabSelect(myFunction); then your function myFunction() receives one param, it is a reference to this object (myObj). myObj.onTabSelect("if (true) return false;"); this is an example with code attached that will be evaluated. #### Tags:
see: | var this._onTabSelectEvent
access: | public
#### Parameters:
mixed | yourEvent | yourEvent (string (of code) or function)
[ Top ] ### method render [line 113]
`string render( )`
#### Tags:
see: | this.draw()
[ Top ] ### method switchTo [line 149]
`void switchTo( newReg theReg)`
switches to the register specified. A paramter you may pass either the caption name of the Tap as string or the Tap index as intger. #### Tags:
access: | public
#### Parameters:
newReg | theReg | mixed string or int
[ Top ] Documentation generated on Mon, 29 Dec 2003 22:18:33 +0100 by phpDocumentor 1.2.3