// JavaScript Document


<!-- Date JS
  function GetDay(intDay){
    var DayArray = new Array("Sunday", "Monday", "Tuesday", "Wednesday", 
                         "Thursday", "Friday", "Saturday")
    return DayArray[intDay]
    }

  function GetMonth(intMonth){
    var MonthArray = new Array("January", "February", "March",
                               "April", "May", "June",
                               "July", "August", "September",
                               "October", "November", "December") 
    return MonthArray[intMonth] 	  	 
    }
  function getDateStrWithDOW(){
    var today = new Date()
    var year = today.getYear()
    if(year<1000) 
	  year+=1900
    var todayStr = GetDay(today.getDay()) + ", "
    todayStr += GetMonth(today.getMonth()) + " " + today.getDate()
    todayStr += ", " + year
    return todayStr
    }
//-->

//Show Hide

		function toggleDisplay(definition)
		{
			if (definition.style.display == 'none')
			{
				definition.style.display=''
			}
			else
			{
				definition.style.display='none'
			}
		}



//Contents for menu 1(Town Resources )
var menu1=new Array()

menu1[0]='<a href="http://spokane.net/town_resources/AdoptAPet.aspx">Adopt A Pet</a>'
menu1[1]='<a href="http://spokane.net/town_resources/CityGuide.aspx"> City Guide</a>'
menu1[2]='<a href="http://spokane.net/town_resources/TownResources.aspx#citymap">City Map</a>'
menu1[3]='<a href="http://spokane.net/town_resources/HistoryObits.aspx">Historic Obits</a>'
menu1[4]='<a href="http://spokane.net/town_resources/TownResourcesContent.aspx?ContentCol=MomentsInTime">Moments In Time</a>'
menu1[5]='<a href="http://spokane.net/town_resources/OurHistory.aspx">Our History</a>'
menu1[6]='<a href="http://spokane.net/town_resources/TownResourcesContent.aspx?ContentCol=pawscorner">Paws Corner</a>'
menu1[7]='<a href="http://spokane.net/town_resources/TownHall.aspx">Town Hall</a>'
menu1[8]='<a href="http://spokane.net/town_resources/volunteering.aspx">Volunteering</a>'



//Contents for menu 2 (Business & Tech)
var menu2=new Array()
menu2[0]='<a href="http://spokane.net/bus_tech/BusinessContent.aspx?ContentCol=DollarsSense">Dollars & Sense</a>'
menu2[1]='<a href="http://spokane.net/bus_tech/economicforecast.aspx">Economic Forecast</a>'
menu2[2]='<a href="http://spokane.net/bus_tech/Business.aspx#Journal">Journal of Business</a>'
menu2[3]='<a href="http://studio-5.financialcontent.com/spokane?Page=MarketSummary">Market Report</a>'
menu2[4]='<a href="http://spokane.net/bus_tech/MotleyFool.aspx">Motley Fool</a>'
menu2[5]='<a href="http://www.moviesforbusiness.com/" target="_blank">Movies for Business</a>'
menu2[6]='<a href="http://spokane.net/bus_tech/Plugged-In/PluggedIn.aspx">Plugged In</a>'
menu2[7]='<a href="http://spokane.net/bus_tech/RealEstate.aspx">Real Estate</a>'
menu2[8]='<a href="http://spokane.gallery.swagit.com/Business_and_Finance/"> Videos</a>'




//Contents for menu 3 (On The Town) 
var menu3=new Array()
menu3[0]='<a href="http://spokane.net/on_town/Attractions.aspx">Attractions</a>'
menu3[1]='<a href="http://spokane.net/on_town/DiningGuidelistnew.aspx">Dining Guide</a>'
menu3[2]='<a href="http://spokane.net/on_town/OnTheTown.aspx#EaterReviews">Eater Reviews</a>'
menu3[3]='<a href="http://spokane.net/on_town/IMAXmovies.aspx">IMAX</a>'
menu3[4]='<a href="http://spokane.net/on_town/LocalTalent.aspx">Local Talent</a>'
menu3[5]='<a href="http://spokane.net/on_town/Movies.aspx">Movies</a>'
menu3[6]='<a href="http://spokane.net/on_town/Nightlife.aspx">Nightlife</a>'
menu3[7]='<a href="http://spokane.net/on_town/OutOfTown.aspx">Out Of Town</a>'
menu3[8]='<a href="http://spokane.net/on_town/onthetown.aspx#SpecialEvents">Special Events</a>'
menu3[9]='<a href="http://spokane.gallery.swagit.com/Arts_and_Entertainment/"> Videos</a>'



//Contents for menu 4 (Sports)
var menu4=new Array()
menu4[0]='<a href="http://spokane.net/sports/chiefs.aspx">Chiefs</a>'
menu4[1]='<a href="http://spokane.net/sports/CollegeCorner.aspx">College Corner</a>'
menu4[2]='<a href="http://spokane.net/sports/Indians.aspx">Indians</a>'
menu4[3]='<a href="http://spokane.net/sports/Sports.aspx#LocalEvents">Local Events</a>'
menu4[4]='<a href="http://spokane.net/sports/Shock.aspx">Shock</a>'
menu4[5]='<a href="http://spokane.net/sports/Sports.aspx#SpecialLinks">Special Links</a>'
menu4[6]='<a href="http://spokane.net/sports/SportsProfile.aspx">Sports Profile</a>'
menu4[7]='<a href="http://spokane.net/sports/SportsContent.aspx?ContentCol=SportingView">A Sporting View</a>'
menu4[8]='<a href="http://spokane.net/sports/SportsContent.aspx?ContentCol=SportsQuiz">Sports Quiz</a>'


//Contents for menu 5 (Stay Connected)
var menu5=new Array()
menu5[0]='<a href="http://pulse.visitspokane.com/index.php"target="_blank" >Calendar</a>'
menu5[1]='<a href="http://classifieds.spokane.net/index.php" target="_blank" >Classifieds</a>'
menu5[2]='<a href="http://community.spokane.net/">Community Groups</a>'
menu5[3]='<a href="http://spokane.net/stay_connected/HotTopics.aspx">Hot Topics</a>'
menu5[4]='<a href="http://spokane.net/stay_connected/LettersEditor.aspx">Letters to the Editor</a>'
menu5[5]='<a href="http://spokane.gallery.swagit.com">Military Gallery</a>'
menu5[6]='<a href="http://spokane.net/stay_connected/News.aspx">News</a>'
menu5[7]='<a href="http://www.people2people.com/?connect=spkrev">Personals</a>'
menu5[8]='<a href="http://spokane.net/stay_connected/PressReleases.aspx">Press Releases</a>'
menu5[9]='<a href="http://spokane.net/stay_connected/SiteIndex.aspx"> Site Index</a>'
menu5[10]='<a href="http://spokane.net/stay_connected/SiteInfo.aspx"> Site Information</a>'
menu5[11]='<a href="http://spokane.gallery.swagit.com/Human_Interest/"> Videos</a>'


//Contents for menu 6 (Help Yourself)
var menu6=new Array()
menu6[0]='<a href="http://spokane.net/help_yourself/BodyAndMore.aspx">Body & More</a>'
menu6[1]='<a href="http://spokane.net/help_yourself/BridesGuide.aspx">Bride&#146s Guide</a>'
menu6[2]='<a href="http://spokane.net/help_yourself/Celebrations.aspx">Celebrations</a>'
menu6[3]='<a href="http://spokane.net/help_yourself/HelpYourselfContent.aspx?ContentCol=DearAbby">Dear Abby</a>'
menu6[4]='<a href="http://spokane.net/help_yourself/doityourself.aspx?url=http://www.diyornot.com/diy/acgb/">Do It Yourself</a>'
menu6[5]='<a href="http://spokane.net/help_yourself/HelpYourselfContent.aspx?ContentCol=DrGizmo">Dr. Gizmo</a>'
menu6[6]='<a href="http://spokane.net/help_yourself/HelpYourselfContent.aspx?ContentCol=HeresATip">Here&#146s A Tip</a>'
menu6[7]='<a href="http://spokane.net/help_yourself/HomeStyle.aspx">HomeStyle</a>'
menu6[8]='<a href="http://spokane.net/help_yourself/YourGarden.aspx">Your Garden</a>'


//Contents for menu 7 (Adventure)
var menu7=new Array()
menu7[0]='<a href="http://spokane.net/Adventure/AtTheTop.aspx">At The Top</a>'
menu7[1]='<a href="http://spokane.net/adventure/Biking.aspx">Biking</a>'
menu7[2]='<a href="http://spokane.net/Adventure/Fishing.aspx">Fishing</a>'
menu7[3]='<a href="http://spokane.net/adventure/Hiking.aspx">Hiking</a>'
menu7[4]='<a href="http://spokane.net/Adventure/Hunting.aspx">Hunting</a>'
menu7[5]='<a href="http://spokane.net/Adventure/Outdoor.aspx">Outdoors</a>'
menu7[6]='<a href="http://spokane.net/Adventure/ThrillSeeking.aspx">Thrill Seeking</a>'
menu7[7]='<a href="http://spokane.net/Adventure/TravelPlanning.aspx">Travel Planning</a>'
menu7[8]='<a href="http://spokane.net/Adventure/TravelSpecials.aspx">Travel Specials</a>'
menu7[9]='<a href="http://spokane.net/Adventure/Weather.aspx">Weather</a>'


//Contents for menu 8 (Fun Stuff)
var menu8=new Array()
menu8[0]='<a href="http://spokane.net/help_yourself/HelpYourselfContent.aspx?ContentCol=7DayMenu">7 Day Menu Planner</a>'
menu8[1]='<a href="http://spokane.net/fun_stuff/CartoonCorner.aspx">Cartoon Corner</a>'
menu8[2]='<a href="http://spokane.net/fun_stuff/FunStuffContent.aspx?ContentCol=CraftCorner">Craft Corner</a>'
menu8[3]='<a href="http://spokane.net/fun_stuff/Games.aspx">Games </a>'
menu8[4]='<a href="http://spokane.net/fun_stuff/FunStuffContent.aspx?ContentCol=horoscopes">Horoscopes</a>'
menu8[5]='<a href="http://spokane.net/fun_stuff/Puzzles.aspx">Puzzles</a>'
menu8[6]='<a href="http://spokane.net/help_yourself/Recipes.aspx">Recipes</a>'
menu8[7]='<a href="http://spokane.net/fun_stuff/FunStuffContent.aspx?ContentCol=bjf">Surfing The Net With Kids</a>'
menu8[8]='<a href="http://spokane.net/fun_stuff/FunStuffContent.aspx?ContentCol=Trivia">Trivia</a>'
menu8[9]='<a href="http://spokane.net/fun_stuff/funstuff.aspx#TV">TV Listings</a>'
menu8[10]='<a href="http://spokane.net/fun_stuff/FunStuffContent.aspx?ContentCol=StrangeTrue">Strange But True</a>'

	
var menuwidth='800px' //default menu width
var menubgcolor='lightyellow'  //menu bgcolor
var disappeardelay=250  //menu disappear speed onMouseout (in miliseconds)
var hidemenu_onclick="yes" //hide menu when user clicks within menu?

/////No further editting needed

var ie4=document.all
var ns6=document.getElementById&&!document.all

if (ie4||ns6)
document.write('<div id="dropmenudiv" style="z-index:99;visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)" ></div>')

function getposOffset(what, offsettype){
var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;
var parentEl=what.offsetParent;
while (parentEl!=null){
totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;
parentEl=parentEl.offsetParent;
}
return totaloffset;
}


function showhide(obj, e, visible, hidden, menuwidth){
ifrmobj=document.getElementById("ifrmZedoSky");
if (ie4||ns6)
dropmenuobj.style.left=dropmenuobj.style.top="-500px"
if (menuwidth!=""){
dropmenuobj.widthobj=dropmenuobj.style
dropmenuobj.widthobj.width=menuwidth
}
if (e.type=="click" && obj.visibility==hidden || e.type=="mouseover")
{
obj.visibility=visible
//ifrmobj.style.right='100px';
//alert(ifrmobj.style.left);
}
else if (e.type=="click")
obj.visibility=hidden
}

function iecompattest(){
return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body
}

function clearbrowseredge(obj, whichedge){
var edgeoffset=0
if (whichedge=="rightedge"){
var windowedge=ie4 && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-15 : window.pageXOffset+window.innerWidth-15
dropmenuobj.contentmeasure=dropmenuobj.offsetWidth
if (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)
edgeoffset=dropmenuobj.contentmeasure-obj.offsetWidth
}
else{
var topedge=ie4 && !window.opera? iecompattest().scrollTop : window.pageYOffset
var windowedge=ie4 && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18
dropmenuobj.contentmeasure=dropmenuobj.offsetHeight
if (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure){ //move up?
edgeoffset=dropmenuobj.contentmeasure+obj.offsetHeight
if ((dropmenuobj.y-topedge)<dropmenuobj.contentmeasure) //up no good either?
edgeoffset=dropmenuobj.y+obj.offsetHeight-topedge
}
}
return edgeoffset
}

function populatemenu(what){
if (ie4||ns6)
dropmenuobj.innerHTML=what.join("")
}


function dropdownmenu(obj, e, menucontents, menuwidth){
if (window.event) event.cancelBubble=true
else if (e.stopPropagation) e.stopPropagation()
clearhidemenu()
dropmenuobj=document.getElementById? document.getElementById("dropmenudiv") : dropmenudiv
populatemenu(menucontents)

if (ie4||ns6){
showhide(dropmenuobj.style, e, "visible", "hidden", menuwidth)

dropmenuobj.x=getposOffset(obj, "left")
dropmenuobj.y=getposOffset(obj, "top")
dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+"px"
dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+obj.offsetHeight+"px"
}

return clickreturnvalue()
}

function clickreturnvalue(){
if (ie4||ns6) return false
else return true
}

function contains_ns6(a, b) {
while (b.parentNode)
if ((b = b.parentNode) == a)
return true;
return false;
}

function dynamichide(e){
if (ie4&&!dropmenuobj.contains(e.toElement))
delayhidemenu()
else if (ns6&&e.currentTarget!= e.relatedTarget&& !contains_ns6(e.currentTarget, e.relatedTarget))
delayhidemenu()
}

function hidemenu(e){
	ifrmobj=document.getElementById("ifrmZedoSky");
	
	if (typeof dropmenuobj!="undefined")
	{
		if (ie4||ns6)
		{
		dropmenuobj.style.visibility="hidden"
		//ifrmobj.style.left-=400;
		}
	}
}//end hidemenu

function delayhidemenu(){
if (ie4||ns6)
delayhide=setTimeout("hidemenu()",disappeardelay)
}

function clearhidemenu(){
if (typeof delayhide!="undefined")
clearTimeout(delayhide)
}

if (hidemenu_onclick=="yes")
document.onclick=hidemenu








