// SIDEMENU - V2.0
// BY: BRIAN GOSSELIN (HTTP://SCRIPTASYLUM.COM)
// ADD YOUR LINKS BELOW.

// TO ADD A HYPERLINK, THE FORMAT IS:                list[x]=new Array('text displayed' , 'url' , 'target' );
// TO ADD A NON-WORKING LINK, THE FORMAT IS:   list[x]=new Array('text displayed' , '' , '' );
// TO ADD A TITLEBAR, THE FORMAT IS:                   list[x]=new Array('text displayed' , null, null );

// KEEP NUMERICAL ORDER. START WITH 1. DO NOT SKIP A NUMBER.

var list=[[],
['<center><b>F11 = Full Page Toggle</b></center>', null , null ],
['<b>       H O M E</b>' , 'index.html', '' ],
['<b>Best Little Links Page in Muskoka! (253kb)</b>' , 'MUSKOKA-LINKS.htm' , '' ],
['<b>Calendar/Conversions/Calculations</b>' , 'MUSKOKA-LINKS.htm#UTILITIES' , '' ],
['<b>Purpose of Site / Webmaster</b>' , 'WEBMASTER.htm' , '' ],
['<b>Hospice Volunteer Hours Submission</b>' , 'HOSPICEMUSKOKA.htm' , '' ],
['<center><b>MHCC Menu is Below</b></center>' ,  null , null ],
['<b>Muskoka Healthy Communities Coalition</b>' , 'MHCC.htm' , '' ],
['<b>MHCC 211 Initiative</b>' , 'MHCC211.htm' , '' ],
['<b>MHCC Contacts</b>' , 'MHCCCONTACT.htm' , '' ],
['<b>MHCC Newspaper Articles</b>' , 'MHCCNEWS.htm' , '' ],
['<b>I Want to Help or Receive Information</b>' , 'MHCCJOIN.htm' , '' ],
['<b>MHCC Mission / Goals / Activities</b>' , 'MHCCMISSION.htm' , '' ],
['<b>MHCC Meetings / Events</b>' , 'MHCCJOIN.htm#CALENDARMEETEVENT' , '' ],
['<b>Email the MHCC</b>' , 'mailto:info@muskokaresource.com' , '' ],
['<center><b>CTRL F = Find on this Page</b><center>' , null , null ]
] 

// VARIOUS SETTINGS/COLORS/TEXT STYLES

var linktextcolor="black";                           // FONT COLOR OF THE LINKS
var linktexthovercolor="#00436e";                 // HOVER COLOR OF LINKS
var linktextsize=1;                                       // FONT SIZE OF THE LINKS (1 TO 6)
var linktextface="verdana";                   // FONT FACE OF THE LINKS
var linkbgcolor="white";                         // BACKGROUND COLOR OF THE LINK BARS
var linkhoverbgcolor="lightyellow";              // BACKGROUND COLOR OF THE LINK BARS AS USER HOVERS OVER THEM
var cellheight=20;                                         // HEIGHT OF LINK BARS IN PIXELS (MIN=20).

var bartextcolor="white";                           // FONT COLOR OF THE "MENU" BAR AND ANY TITLEBARS
var bartextsize=1;                                       // FONT SIZE OF THE MENU/TITLE BARS
var bartextface="verdana";                   // FONT FACE OF THE MENU/TITLE BARS
var barbgcolor="#475F65";                                // BACKGROUND COLOR OF THE MENU/TITLE BARS

var bordercolor="black";                           // BORDER COLOR SURROUNDING ALL BARS

var barwidth=30;                                        // WIDTH OF THE "MENU" BAR (SET WIDE ENOUGH SO LINKTEXT DOESN'T WRAP)
var follow=true;                                          // true=MENU FOLLOWS PAGE SCROLL, false=MENU IS STATIONARY
var menuwidth=250;                                    // WIDTH OF TEXT LINK BARS
var yoffset=-12;                                           // OFFSET FROM TOP OF THE PAGE


//*********DO NOT EDIT BEYOND THIS POINT**********//
var smenu, pagedone=false, id, loff=1;
linktextsize=Math.max(Math.min(linktextsize,6),1);
if(linktextsize>6)linktextsize=6; if(linktextsize<1)linktextsize=1;
if((linktextsize*5+10)>cellheight)cellheight=Math.max(20,(linktextsize*5+10));
var btbl='<table cellpadding="0" cellspacing="0" border="0"  width="'+menuwidth+'"><tr><td valign="center" width="'+menuwidth+'" height="'+cellheight+'" ';
var NS4=(navigator.appName.indexOf("Netscape")>=0 && parseFloat(navigator.appVersion) >= 4 && parseFloat(navigator.appVersion) < 5)? true : false;
var IE4=(document.all)? true : false;
var NS6=(parseFloat(navigator.appVersion) >= 5 && navigator.appName.indexOf("Netscape")>=0 )? true: false;
var txt=(NS4)?'<layer name="smenu" bgcolor="'+bordercolor+'" top="0" left="0" onmouseover="showmenu(true)" width="'+(menuwidth+barwidth+3)+'" visibility="hide" onmouseout="showmenu(false)">' : '<div id="smenu" style="width:'+(menuwidth+barwidth+3)+'; position:absolute; right:0px; top:0px; background-color:'+bordercolor+'; visibility:hidden" onmouseover="showmenu(true)" onmouseout="showmenu(false)">';
txt+='<table cellpadding="0" cellspacing="1" border="0" bgcolor="'+bordercolor+'" width="'+(menuwidth+barwidth+3)+'">';
for(i=1;i<list.length;i++){
if(list[i][1]!=null){
txt+='<tr><td width="'+menuwidth+'" height="'+cellheight+'">';
txt+=(NS4)?'<ilayer>' : '<div style="position:relative; width:'+menuwidth+'px; height:'+cellheight+'px;">';
txt+=(NS4)?'<layer name="h'+(i-loff)+'" height="'+cellheight+'" visibility="hide" bgcolor="'+linkhoverbgcolor+'">'+btbl+' bgcolor="'+linkhoverbgcolor+'"><font color="'+linktexthovercolor+'" size="'+linktextsize+'" face="'+linktextface+'">&nbsp;'+list[i][0]+'</font></td></tr></table></layer>' : '<div id="h'+i+'" style="position:absolute; top:0px; left:0px; width:'+menuwidth+'px; height:'+cellheight+'px; background-color:'+linkhoverbgcolor+';">'+btbl+' bgcolor="'+linkhoverbgcolor+'"><font color="'+linktexthovercolor+'" size="'+linktextsize+'" face="'+linktextface+'">&nbsp;'+list[i][0]+'</font></td></tr></table></div>';
txt+=(NS4)?'<layer name="n'+(i-loff)+'" height="'+cellheight+'" bgcolor="'+linkbgcolor+'">'+btbl+' bgcolor="'+linkbgcolor+'"><font color="'+linktextcolor+'" size="'+linktextsize+'" face="'+linktextface+'">&nbsp;'+list[i][0]+'</font></td></tr></table></layer>' : '<div id="n'+i+'" style="position:absolute; top:0px; left:0px; width:'+menuwidth+'px; height:'+cellheight+'px; background-color:'+linkbgcolor+';">'+btbl+' bgcolor="'+linkbgcolor+'"><font color="'+linktextcolor+'" size="'+linktextsize+'" face="'+linktextface+'">&nbsp;'+list[i][0]+'</font></td></tr></table></div>';
txt+=(NS4)?'<layer height="'+cellheight+'" onmouseover="hoverlayer(\'h\',\'n\','+(i-loff)+')" onmouseout="hoverlayer(\'n\',\'h\','+(i-loff)+')">' : '<div style="position:absolute; top:0px; left:0px; width:'+menuwidth+'px; height:'+cellheight+'px;" onmouseover="hoverlayer(\'h\',\'n\','+i+')" onmouseout="hoverlayer(\'n\',\'h\','+i+')">'+btbl+'>';
txt+='<a href="'+list[i][1]+'" target="'+list[i][2]+'"><img src="blank.gif" width="'+menuwidth+'" height="'+cellheight+'" border="0"></a>';
txt+=(NS4)?'</layer></ilayer></td>' : '</td></tr></table></div></div></td>';
}else{
txt+='<tr height="'+cellheight+'"><td width="'+menuwidth+'" bgcolor="'+barbgcolor+'" height="'+cellheight+'" valign="center"><font color="'+bartextcolor+'" size="'+linktextsize+'" face="'+linktextface+'">'+list[i][0]+'</font></td>';
loff+=1;
}
if(i==1)txt+='<td rowspan="'+(list.length-1)+'" bgcolor="'+barbgcolor+'" width="'+barwidth+'" height="'+cellheight+'" align="center"><font color="'+bartextcolor+'" size="'+bartextsize+'" face="'+bartextface+'"><b>M<br>E<br>N<br>U</b></font></td>';
txt+='</tr>';
}
txt+='</table>';
txt+=(NS4)?'</layer>' : '</div>';
document.write(txt);

function hoverlayer(h,n,num){
if(NS6){
document.getElementById(h+num).style.visibility="visible";
document.getElementById(n+num).style.visibility="hidden";
}
if(IE4){
document.all[h+num].style.visibility="visible";
document.all[n+num].style.visibility="hidden";
}
if(NS4){
smenu.document.layers[num].document.layers[h+num].visibility="show";
smenu.document.layers[num].document.layers[n+num].visibility="hide";
}}
function init(){
if(NS4){
smenu=document.smenu;
movexto(-menuwidth-2);
smenu.visibility="show";
}
else if(IE4){
smenu=document.all.smenu;
movexto(-menuwidth-2);
smenu.style.visibility="visible";
}
else if(NS6){
smenu=document.getElementById('smenu');
movexto(-menuwidth-2);
smenu.style.visibility="visible";
}
pagedone=true;
setInterval('movemenu()', 75);
}
function movemenu(){
if(follow){
var y=(NS4)?smenu.top:parseInt(smenu.style.top);
var sy=(IE4||IE5)?document.body.scrollTop:window.pageYOffset;
moveyto(((sy-y+yoffset)/3+3)+y);
}}
function showmenu(toshow){
if(pagedone){
if(toshow){
clearTimeout(id);
movexto(0);
}else id=setTimeout('movexto(-menuwidth-2)',200);
}}
function movexto(x){
if(NS4)smenu.left=x;
if(IE4||NS6)smenu.style.left=x+'px';
}
function moveyto(y){
if(NS4)smenu.top=y;
if(IE4||NS6)smenu.style.top=y+'px';
}
if(NS4)window.onresize=new Function("history.go(0)");
window.onload=init;