/* --------------------------------------- */
/* INITIAL FUNCTIONS */
/* --------------------------------------- */

var pageId;



/* --------------------------------------- */
/* INITIAL FUNCTIONS */
/* --------------------------------------- */

// window.domready Events
window.addEvent('domready', function()
{

	pageId = initialPageId;
	loadExtendedContent(pageId);

});

// window.load Events
window.addEvent('load', function () 
{
});



/**
 *
 */
function loadExtendedContent(pageId)
{
	switch (pageId)
	{
		case 'termine':
		case 'terminarchiv':
			accordionMusicTerm();
			break;
		default:
			break;
	}     
}
 

/**
 *
 */
function unloadExtendedContent(pageId)
{
	switch (pageId)
	{
		default:
			break;
	}     
}
 

/* --------------------------------------- */
/* ACCORDION FUNCTIONS */
/* --------------------------------------- */

/**
 *
 */
function accordionMusicTerm()
{
	var accordion = new Accordion (
		'div.musicTermDivHead', 
		'div.musicTermDivBody', 
		{
			alwaysHide: true,
			opacity: true
		}, 
		$('musicTermAccordion')
	);
	
	$('musicTermAccordion').getElements('.musicTermDivHead').each(function(link)
    {
    	var parentDiv = link.getParent();
		link.addEvent('mouseenter', function ()
        {
        	parentDiv.highlight('#EEEEEE');
        });
    });
	
}



