if (/MSIE 6/i.test(navigator.userAgent)){   
$(document).ready(function() {

	$(".SubNav li").prepend("<span></span>"); //Throws an empty span tag right before the a tag

	$(".SubNav li").each(function() { //For each list item...
		var linkText = $(this).find("a").html(); //Find the text inside of the <a> tag
		$(this).find("span").show().html(linkText); //Add the text in the <span> tag
	}); 

	$(".SubNav li").hover(function() {	//On hover...
		$(this).find("span").stop().animate({
			marginTop: "-24" //Find the <span> tag and move it up 40 pixels
		}, 300);
	} , function() { //On hover out...
		$(this).find("span").stop().animate({
			marginTop: "0"  //Move the <span> back to its original state (0px)
		}, 300);
	});

});

ddaccordion.init({
	headerclass: "Header", //Shared CSS class name of headers group
	contentclass: "HideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
	defaultexpanded: ["0h"], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: true, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	togglehtml: ["suffix", "<img src='/extension/safp/design/safp/images/nav_arrow.gif' class='statusicon' />", "<img src='/extension/safp/design/safp/images/nav_arrow_ho.gif' class='statusicon' />"], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
	animatespeed: "fast" //speed of animation: "fast", "normal", or "slow"
})

ddaccordion.init({
	headerclass: "LinkHeader", //Shared CSS class name of headers group
	contentclass: "LinkHideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: true, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	animatespeed: "fast", //speed of animation: "fast", "normal", or "slow"
        oninit:function(expandedindices){ //custom code to run when headers have initalized
        //do nothing
        ddaccordion.expandall('LinkHeader');
	},
	onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
		//do nothing
	}
})
ddaccordion.init({
	headerclass: "NewsHeader", //Shared CSS class name of headers group
	contentclass: "NewsHideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: false, //Collapse previous content (so only one open at any time)? true/false 
	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: false, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	togglehtml: ["suffix", "<img src='/extension/safp/design/safp/images/nav_arrow.gif' class='statusicon' />", "<img src='/extension/safp/design/safp/images/nav_arrow_ho.gif' class='statusicon' />"], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
	animatespeed: "fast", //speed of animation: "fast", "normal", or "slow"
	oninit:function(expandedindices){ //custom code to run when headers have initalized
		//do nothing
		ddaccordion.expandall('NewsHeader');
	},
	onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
		//do nothing
	}
})
}
else {
$(document).ready(function() {

	$(".SubNav li").prepend("<span></span>"); //Throws an empty span tag right before the a tag

	$(".SubNav li").each(function() { //For each list item...
		var linkText = $(this).find("a").html(); //Find the text inside of the <a> tag
		$(this).find("span").show().html(linkText); //Add the text in the <span> tag
	}); 

	$(".SubNav li").hover(function() {	//On hover...
		$(this).find("span").stop().animate({
			marginTop: "-24" //Find the <span> tag and move it up 40 pixels
		}, 300);
	} , function() { //On hover out...
		$(this).find("span").stop().animate({
			marginTop: "0"  //Move the <span> back to its original state (0px)
		}, 300);
	});

});

ddaccordion.init({
	headerclass: "Header", //Shared CSS class name of headers group
	contentclass: "HideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
	defaultexpanded: ["0h"], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: true, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	togglehtml: ["suffix", "<img src='/extension/safp/design/safp/images/nav_arrow.png' class='statusicon' />", "<img src='/extension/safp/design/safp/images/nav_arrow_ho.png' class='statusicon' />"], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
	animatespeed: "fast" //speed of animation: "fast", "normal", or "slow"
})

ddaccordion.init({
	headerclass: "LinkHeader", //Shared CSS class name of headers group
	contentclass: "LinkHideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: true, //Collapse previous content (so only one open at any time)? true/false
	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: true, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	animatespeed: "fast", //speed of animation: "fast", "normal", or "slow"
        oninit:function(expandedindices){ //custom code to run when headers have initalized
        //do nothing
        ddaccordion.expandall('LinkHeader');
	},
	onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
		//do nothing
	}
})
ddaccordion.init({
	headerclass: "NewsHeader", //Shared CSS class name of headers group
	contentclass: "NewsHideArea", //Shared CSS class name of contents group
	revealtype: "click", //Reveal content when user clicks or onmouseover the header? Valid value: "click" or "mouseover"
	collapseprev: false, //Collapse previous content (so only one open at any time)? true/false 
	defaultexpanded: [], //index of content(s) open by default [index1, index2, etc]. [] denotes no content.
	animatedefault: false, //Should contents open by default be animated into view?
	persiststate: false, //persist state of opened contents within browser session?
	toggleclass: ["", ""], //Two CSS classes to be applied to the header when it's collapsed and expanded, respectively ["class1", "class2"]
	togglehtml: ["suffix", "<img src='/extension/safp/design/safp/images/nav_arrow.png' class='statusicon' />", "<img src='/extension/safp/design/safp/images/nav_arrow_ho.png' class='statusicon' />"], //Additional HTML added to the header when it's collapsed and expanded, respectively  ["position", "html1", "html2"] (see docs)
	animatespeed: "fast", //speed of animation: "fast", "normal", or "slow"
	oninit:function(expandedindices){ //custom code to run when headers have initalized
		//do nothing
		ddaccordion.expandall('NewsHeader');
	},
	onopenclose:function(header, index, state, isuseractivated){ //custom code to run whenever a header is opened or closed
		//do nothing
	}
})
}
