// JScript File

//   MAIN FUNCTION: new switchcontent("class name", "[optional_element_type_to_scan_for]") REQUIRED
//1) Instance.setStatus(openHTML, closedHTML)- Sets optional HTML to prefix the headers to indicate open/closed states
//2) Instance.setColor(openheaderColor, closedheaderColor)- Sets optional color of header when it's open/closed
//3) Instance.setPersist(true/false)- Enables or disabled session only persistence (recall contents' expand/contract states)
//4) Instance.collapsePrevious(true/false)- Sets whether previous content should be contracted when current one is expanded
//5) Instance.defaultExpanded(indices)- Sets contents that should be expanded by default (ie: 0, 1). Persistence feature overrides this setting!
//6) Instance.init() REQUIRED

var bobexample1=new switchcontent("switchgroup1", "div") //Limit scanning of switch contents to just "div" elements
bobexample1.setStatus('<img src="images/close.gif" style="margin:2px; border:0" alt="Gizle" /> ', '<img src="images/open.gif" style="margin:2px; border:0" alt="Göster" /> ')
bobexample1.setColor('darkred', '#4f6b72')
bobexample1.setPersist(true)
bobexample1.collapsePrevious(false) //Only one content open at any given time
bobexample1.init()

var bobexample2=new switchcontent("switchgroup2", "div") //Limit scanning of switch contents to just "div" elements
bobexample2.setStatus('<img src="images/close.gif" style="margin:2px; border:0" alt="Gizle" />', '<img src="images/open.gif" style="margin:2px; border:0" alt="Göster" />')
bobexample2.setColor('darkred', '#4f6b72')
bobexample2.setPersist(true)
bobexample2.collapsePrevious(false) //Only one content open at any given time
bobexample2.init()

var bobexample3=new switchcontent("switchgroup3", "div") //Limit scanning of switch contents to just "div" elements
bobexample3.setStatus('<img src="images/close.gif" style="margin:2px; border:0" alt="Gizle" />', '<img src="images/open.gif" style="margin:2px; border:0" alt="Göster" />')
bobexample3.setColor('darkred', '#4f6b72')
bobexample3.setPersist(true)
bobexample3.collapsePrevious(false) //Only one content open at any given time
bobexample3.init()
