/************************************
IMPORTANT!
1) Create a folder called "variables" in the root folder of the website you are working 
on and save this file into it as "advExpandVariables.js"
This keeps the variables accessible from one location.

2) "Instance" in the variables below needs to be changed to something unique 
so it doesn't interfere with how this is implemented on other
Park Nicollet websites.
*************************************/

/* -------------------------------------------------------------------

EXPANDABLE CONTENT VARIABLES

Implemented: 1-10-2007
Supports: FF1+ IE5+ Opr7+

Features:
- Multiple expandable content groups can be on one page and work independently
- Infinite nesting of expandable content

VARIABLE OPTIONS:
   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. Important: If you don't want the default image displayed add a space between the quotes.
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, 7, 12). Persistence feature overrides this setting!
6) Instance.init() REQUIRED

Options that are not required can be deleted or even left blank.

------------------------------------------------------------------- */

// DEMO 1
var cstmReadingList=new switchcontent("readingGroup1", "div") /* REQUIRED - Limits scanning of expandable contents to just "div" elements. 
You can use any HTML elements, such as table, span, p, etc.*/ 
cstmReadingList.setStatus('', '')
cstmReadingList.setColor('#FFFFFF', '#FFFFFF')
cstmReadingList.setPersist(true)
cstmReadingList.collapsePrevious(true)
cstmReadingList.defaultExpanded()
cstmReadingList.init() /* REQUIRED */