var ns6=document.getElementById&&!document.all var ie4=document.all&&navigator.userAgent.indexOf("Opera")==-1 var head="display:''" // This variables for random News Window var image = new Array(); var desc = new Array(); image[1] = "/images/news/orientation2010.jpg"; desc[1] = "

Orientation Day for Incoming 7th & 9th Graders

Wednesday, September 1

Incoming 9th graders in the auditorium at 9:00
Incoming 7th graders in the auditorium at 11:00
Returning 9th graders in the cafeteria at 10:00

"; image[2] = "/images/news/distrubition2010.jpg"; desc[2] = "

Program Distribution for Grades 8,10,11, & 12

Thursday, September 2

Grade 8 in the cafeteria at 9:30
Grade 12 in the library at 10:00
Grade 11 in the cafeteria at 10:30
Grade 10 in the library at 11:00

"; image[3] = "/images/news/alumnibasketball2008.gif"; desc[3] = "

Summer Hoops

Monday & Wednesday Nights from 5-9:00PM

Location: ERHS South Gym

Gym access is limited to players on the tryout roster.

View Flyer

"; var array_size = image.length-1; var keepid; var timerID = null; // End function popper(sHow, iWidth, iHeight){ popupWin = window.open("/news/index.php?id="+ sHow, 'popupWin', 'width='+iWidth+',height='+iHeight+',status=yes,toolbar=no,menubar=no,location=no'); if(window.focus){ popupWin.focus(); } return false; } function isHeader(elm){ var islist=0 varElm=ns6? elm.target : event.srcElement if (varElm.id=="folder") islist=1 else while (ns6&&varElm.parentNode||(ie4&&varElm.parentElement)){ if (varElm.className=="folder"||varElm.className=="subfolder"){ islist=(varElm.className=="folder")? 1 : 0 break} varElm=ns6? varElm.parentNode : varElm.parentElement} if (islist){ var list=ns6? varElm.nextSibling.nextSibling : varElm.all.tags("UL")[0] if (list.style.display=="none"){ list.style.display="" } else { list.style.display="none" } } } if (ie4||ns6) document.onclick=isHeader function inspect(elm){ var str = ""; for(var i in elm){ str += i + ": " + elm.getAttribute(i) + "\n"; } alert(str); } $(document).ready(function(){ jQuery.easing.def = 'easeOutBounce'; $(".nav").each(function(){ var cookiemenu = $(this).attr("id")+"menu"; var effectedMenu = $(this).attr("id"); if($.cookie('collapsed'+cookiemenu)=='true'){ // $("#"+cookiemenu).show(); $("#"+cookiemenu).css("display","block"); $("#"+effectedMenu).addClass("active"); } else { // $("#"+cookiemenu).hide(); $("#"+cookiemenu).css("display","none"); $("#"+effectedMenu).removeClass("active"); } }); $(".nav").click(function(){ var menu = $(this).attr("id"); if($.browser.safari && $.browser.version <= 419){ $("#"+menu+"menu").toggle(); } else { $("#"+menu+"menu").animate({ height: "toggle", opacity: "toggle" }, { duration: 1000 ,"easing": "easeOutQuad" }); } if($.cookie("collapsed"+menu+"menu")=='true'){ $("#"+menu).removeClass("active"); $.cookie("collapsed"+menu+"menu",null, { path: '/', domain: 'erhs.la' }); } else { $("#"+menu).addClass("active"); $.cookie("collapsed"+menu+"menu","true", { path: '/', domain: 'erhs.la' }); } }); function newselect(id){ if(timerID != null){ clearTimeout(timerID); } jQuery.each(desc, function(index, value){ if(index == id){ $("#news"+id).css({'backgroundColor':'#E1E1E1'}); } else { $("#news"+index).css({'backgroundColor':'#FFFFFF'}); } }); timerID = window.setTimeout(function(){moveright();},8000); } $("a[id*='news']").click(function(){ var id = $(this).attr("name"); $("#newsimage").css({'backgroundImage' : 'url('+image[id]+')', 'backgroundRepeat' : 'no-repeat', 'backgroundPosition' : 'left'}); $("#newswindow").html(desc[id]); newselect(id); }); function moveright(){ if(keepid == array_size){ keepid = 1; } else { keepid++; } $("#newsimage").css({'backgroundImage' : 'url('+image[keepid]+')', 'backgroundRepeat' : 'no-repeat', 'backgroundPosition' : 'left'}); $("#newswindow").html(desc[keepid]); newselect(keepid); } $("#moveright").click(moveright); function moveleft(){ if(keepid > 1){ keepid--; } else { keepid = array_size; } $("#newsimage").css({'backgroundImage' : 'url('+image[keepid]+')', 'backgroundRepeat' : 'no-repeat', 'backgroundPosition' : 'left'}); $("#newswindow").html(desc[keepid]); newselect(keepid); } $("#moveleft").click(moveleft); var newscount = array_size; var randomnumber = Math.random() ; var rand1 = Math.round( (newscount-1) * randomnumber) + 1; keepid = rand1; $("#newsimage").css({'backgroundImage' : 'url('+image[rand1]+')', 'backgroundRepeat' : 'no-repeat', 'backgroundPosition' : 'left'}); $("#newswindow").html(desc[rand1]); newselect(keepid); });