//<!-- menu -->
// Menu ASP
// Nicola Zordan, Monday 30 December 2001

var MenuArray;

var MenuArrayLoggedIn, MenuArrayLoggedOut, MenuArrayLoggedInDemo;

var MenuAlert=[
 ["<font color='red'>News</font>",'News.asp',DateYMD(2002,12,30),DateYMD(2003,1,30)]
// ,["<font color='red'>WATCH</font>",'Watch.asp',DateYMD(2008,8,14),DateYMD(2008,8,24)]
 ,["<font 0color='brown' color='red' size='+1'>ALERT</font>",'Alert.asp',DateYMD(2008,8,14),DateYMD(2008,8,24)]
]; 

MenuArrayLoggedOut = [
//['Label','URL'],
//-["<font color='red'>News</font>",'News.asp',DateYMD(2002,12,30),DateYMD(2003,1,30)],
//-["<font color='red'>Watch</font>",'Watch.asp',DateYMD(2008,8,14),DateYMD(2008,8,30)],
//-["<font color='red'>Alert</font>",'Alert.asp',DateYMD(2002,12,30),DateYMD(2003,1,30)],


//['Login','Login.asp'],
['<font color="red">Login</font>','Login.asp'],
//['<font color="red">LOGIN</font>','Login.asp'],
['Zones','index.asp'],
//['Zones','ZoneMaps.asp'],
['Weather','Weather.asp'],
//['C-Ed','Education.asp'],
['Classes','Classes.asp'],
['Calendar','Calendar.asp'],
['BLog','BLog.asp'],
['Quiz','Quiz.asp'],
['Photos','Photos.asp'],
['Collaboration','Collaboration.asp'],

//-['Photos','photos.asp'],

//['Comments','Comments.asp'],
//-['Search','Search.asp'],
//-['Links','Links.asp'],

//-['Galnce','RotatingPhotos.asp'],

//['Other Pages','UnderConstruction.asp'],

//['Demo','indexDemo.asp'],

//['<a href="http://escati.linkopp.net/counter2001/377673.shtml"><img src="http://escati.linkopp.net/cgi-bin/counter2001.cgi?377673" border="0"alt="Escati counter"></a>',''],
//['<a href="http://profiles.yahoo.com/Nicola_Zordan"><img border=0 src="http://opi.yahoo.com/online?u=nicola_zordan&m=g&t=3" alt="Yahoo!: Nicola_Zordan"></a>&nbsp',""],
//['<a href="'+"JavaScript:document.all.Logo.innerHTML='';document.all.MenuTopDiv.innerHTML='';document.all.Menu.innerHTML='';alert('Use Refresh to redisplay menus')"+'"><img src="printable.gif" border="0" alt="Printable"><small><!--printable--></small></a>',""],
['<a href="'+"JavaScript:ToPrint('Print')"+'"><img src="printable.gif" border="0" alt="Print"/></a>',""],

//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],

['<SMALL><B>NZ</B></SMALL>','http://www.NicolaZordan.net/Nik/contacti.asp']
];


MenuArrayLoggedIn = [
//['Label','URL'],


//[LoggedIn,''],
//[LoggedIn+' <small><a href="javascript:if (confirm(\'Confirm Logout ?\')) UserLogOut()">logout</a></small>',''],
//['LoggedIn',''],
//-["<font color='red'>News'</font>",'News.asp',DateYMD(2002,12,30),DateYMD(2003,1,30)],

//-['Logout','javascript:if (confirm(\'Confirm Logout ?\')) UserLogOut()'],
['Zones','index.asp'],
//['Zones','ZoneMaps.asp'],
['Weather','Weather.asp'],
['Classes','Classes.asp'],
['Calendar','Calendar.asp'],
['BLog','BLog.asp'],
['Quiz','Quiz.asp'],
['Photos','Photos.asp'],
['Collaboration','Collaboration.asp'],

//-['Photos','photos.asp'],

//['Comments','Comments.asp'],
//-['Search','Search.asp'],
//-['Links','Links.asp'],

//-['Galnce','RotatingPhotos.asp'],

//['Other Pages','UnderConstruction.asp'],

//['<a href="http://escati.linkopp.net/counter2001/377673.shtml"><img src="http://escati.linkopp.net/cgi-bin/counter2001.cgi?377673" border="0"alt="Escati counter"></a>',''],
//['<a href="http://profiles.yahoo.com/Nicola_Zordan"><img border=0 src="http://opi.yahoo.com/online?u=nicola_zordan&m=g&t=3" alt="Yahoo!: Nicola_Zordan"></a>&nbsp',""],
//['<a href="'+"JavaScript:document.all.Logo.innerHTML='';document.all.MenuTopDiv.innerHTML='';document.all.Menu.innerHTML='';alert('Use Refresh to redisplay menus')"+'"><img src="printable.gif" border="0" alt="Printable"><small><!--printable--></small></a>',""],
['<a href="'+"JavaScript:ToPrint('Print')"+'"><img src="printable.gif" border="0" alt="Print"/></a>',""],

//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],

[LoggedIn+' <small><a href="javascript:if (confirm(\'Confirm Logout ?\')) UserLogOut()">logout</a></small>',''],

['<SMALL><B>NZ</B></SMALL>','http://www.NicolaZordan.net/Nik/contacti.asp']
];


MenuArrayLoggedInDemo = [
//['Label','URL'],


//[LoggedIn,''],
//[LoggedIn+' <small><a href="javascript:if (confirm(\'Confirm Logout ?\')) UserLogOut()">logout</a></small>',''],
//['LoggedIn',''],
//-["<font color='red'>News'</font>",'News.asp',DateYMD(2002,12,30),DateYMD(2003,1,30)],

//--['Logout','javascript:UserLogOut()'],
['Zones','indexDemo.asp'],
//['Zones','ZoneMaps.asp'],
['Weather','Weather.asp'],
['Classes','Classes.asp'],
['Calendar','Calendar.asp'],
['BLog','BLog.asp'],
['Quiz','Quiz.asp'],
['Photos','Photos.asp'],
['Collaboration','Collaboration.asp'],

//-['Photos','photos.asp'],

//['Comments','Comments.asp'],
//-['Search','Search.asp'],
//-['Links','Links.asp'],

//-['Galnce','RotatingPhotos.asp'],

//['Other Pages','UnderConstruction.asp'],

//['<a href="http://escati.linkopp.net/counter2001/377673.shtml"><img src="http://escati.linkopp.net/cgi-bin/counter2001.cgi?377673" border="0"alt="Escati counter"></a>',''],
//['<a href="http://profiles.yahoo.com/Nicola_Zordan"><img border=0 src="http://opi.yahoo.com/online?u=nicola_zordan&m=g&t=3" alt="Yahoo!: Nicola_Zordan"></a>&nbsp',""],
//['<a href="'+"JavaScript:document.all.Logo.innerHTML='';document.all.MenuTopDiv.innerHTML='';document.all.Menu.innerHTML='';alert('Use Refresh to redisplay menus')"+'"><img src="printable.gif" border="0" alt="Printable"><small><!--printable--></small></a>',""],
['<a href="'+"JavaScript:ToPrint('Print')"+'"><img src="printable.gif" border="0" alt="Print"/></a>',""],

//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],
//['Dddd','Page3.asp'],

[LoggedIn+' <small><a href="javascript:if (confirm(\'Confirm Logout ?\')) UserLogOut()">logout</a></small>',''],

['<SMALL><B>NZ</B></SMALL>','http://www.NicolaZordan.net/Nik/contacti.asp']
];


MenuArrayAdmin = [
//['Label','URL'],
  ['@','UsersUpdate.asp'],
  ['#','MembersUpdate.asp'],

['<SMALL><B>NZ</B></SMALL>','http://www.NicolaZordan.net/Nik/contacti.asp']
];

//MenuArray = [
////['Label','URL'],
//['<SMALL><B>NZ</B></SMALL>','http://www.NicolaZordan.net/Nik/contacti.asp']
//];

if (LoggedIn!=null) {
  //MenuArray=MenuArrayLoggedIn;
  MenuArray=MenuAlert.concat(MenuArrayLoggedIn);
  //if (LoggedIn==DemoUser) MenuArray=MenuArrayLoggedInDemo;
  if (LoggedIn.toUpperCase()==DemoUser.toUpperCase()) {
    //-MenuArray=MenuArrayLoggedInDemo;
    MenuArray=MenuAlert.concat(MenuArrayLoggedInDemo);
   } else {
    if (LoggedIn.toUpperCase()==AdminUser.toUpperCase()) {
      //-var last=MenuArray[MenuArray.length-1];
      //-MenuArray[MenuArray.length-1]=['@','UsersUpdate.asp'];
      //-MenuArray[MenuArray.length]=last;

/*
      var last=MenuArray[MenuArray.length-1];
      MenuArray[MenuArray.length]=last;
      MenuArray[MenuArray.length-2]=MenuArray[MenuArray.length-3];
      MenuArray[MenuArray.length-3]=['@','UsersUpdate.asp'];
*/

      //-MenuArrayAdmin=MenuAlert.concat(MenuArrayAdmin);
      var last;
      for (var i=0;i<MenuArrayAdmin.length-1;i++) {
        last=MenuArray[MenuArray.length-1];
        MenuArray[MenuArray.length]=last;
        MenuArray[MenuArray.length-2]=MenuArray[MenuArray.length-3];
        MenuArray[MenuArray.length-3]=MenuArrayAdmin[i];
      };

      //-MenuArray[MenuArray.length]=['@','UsersUpdate.asp'];
      //-MenuArray[MenuArray.length]=null;
    };
  };  
 } else {
  //-MenuArray=MenuArrayLoggedOut;
  MenuArray=MenuAlert.concat(MenuArrayLoggedOut);
};

//  MenuArray=MenuArrayLoggedOut;


//var Menu=new Array();

//Menu[Menu.length]= new MenuItem('Label','URL');
//alert(MenuArray.length);
//var Menu=Array2MenuItems(MenuArray);
var MenuTop=Array4MenuItems(MenuArray);


//CustomMenuLabelBefore='<b><font face="Arial" onMouseOver="this.color=\'red\'" onMouseOut="this.color=\'\'">';
CustomMenuLabelBefore='<p align="center"><b><font face="Century gothic, Arial" color="white" style="{text-decoration: none}">';
CustomMenuLabelAfter='</font></b>';

CustomMenuAttributes='border="0" cellpadding="0" cellspacing="0"';
CustomMenuNormalBgColor='';

CustomMenuCornerTL='corner_tl_silver.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_silver.gif';
CustomMenuCornerBR='corner_br_silver.gif';
CustomMenuCornerBL='corner_bl_silver.gif';
//CustomMenuFixedWidth=true;
CustomMenuFixedWidth=false;
CustomMenuFixedWidth=true;

CustomMenuCornerTL='corner_tl_valdagno.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_valdagno.gif';
CustomMenuCornerBR='corner_br_valdagno.gif';
CustomMenuCornerBL='corner_bl_valdagno.gif';

CustomMenuCornerTL='corner_tl_valdagno_bar.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_valdagno_bar.gif';
CustomMenuCornerBR='corner_br_valdagno_bar.gif';
CustomMenuCornerBL='corner_bl_valdagno_bar.gif';

CustomMenuCornerTL='corner_tl_world.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_world.gif';
CustomMenuCornerBR='corner_br_world.gif';
CustomMenuCornerBL='corner_bl_world.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCornerTL='corner_tl_333366.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_333366.gif';
CustomMenuCornerBR='corner_br_333366.gif';
CustomMenuCornerBL='corner_bl_333366.gif';

CustomMenuCornerTL='corner_tl_silver.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_silver.gif';
CustomMenuCornerBR='corner_br_silver.gif';
CustomMenuCornerBL='corner_bl_silver.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';


CustomMenuCornerTL='corner_tl_white.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_white.gif';
CustomMenuCornerBR='corner_br_white.gif';
CustomMenuCornerBL='corner_bl_white.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCornerTL='corner_tl_world.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_world.gif';
CustomMenuCornerBR='corner_br_world.gif';
CustomMenuCornerBL='corner_bl_world.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';


CustomMenuCornerTL='corner_tl_valdagno.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_valdagno.gif';
CustomMenuCornerBR='corner_br_valdagno.gif';
CustomMenuCornerBL='corner_bl_valdagno.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCornerTL='corner_tl_valdagnoDark.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_valdagnoDark.gif';
CustomMenuCornerBR='corner_br_valdagnoDark.gif';
CustomMenuCornerBL='corner_bl_valdagnoDark.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCornerTL='corner_tl_white.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_white.gif';
CustomMenuCornerBR='corner_br_white.gif';
CustomMenuCornerBL='corner_bl_white.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';


CustomMenuSelectColor='yellow';
CustomMenuSelectColor='black';
CustomMenuNormalBgColor='white';
CustomMenuNormalBgColor='black';
//CustomMenuNormalBgColor='';
//CustomMenuCurrentColor='cyan';
CustomMenuCurrentColor='white';
CustomMenuCurrentColor='#EEEFF4';
//CustomMenuNormalBgColor='silver';
//CustomMenuNormalBgColor='#99bbee';
CustomMenuCurrentColor='gray';

//CustomMenuOrizzontal=false;
CustomMenuOrizzontal=true;
//CustomMenuFixedWidth=false;
//CustomMenuCornerTL='';
//CustomMenuCornerBR='';
//CustomMenuCornerBL='';
CustomMenuNormalBgColor='';
//CustomMenuNormalBgColor='white';
//CustomMenuNormalBgColor='#666699';
CustomMenuNormalBgColor='gray';
CustomMenuNormalBgColor='silver';
CustomMenuNormalBgColor='#efefcf';
CustomMenuNormalBgColor='#ffffcf';
CustomMenuNormalBgColor='#ffffcc';
CustomMenuNormalBgColor='#ffffbb';
CustomMenuNormalBgColor='white';
CustomMenuNormalBgColor='silver';

// Bar underneath the tabs
//*CustomMenuText='';
//CustomMenuText='Main orizzontal menu';
//CustomMenuText=' ';
//CustomMenuText='Test main page folder index';
//*CustomMenuText='<font color="silver">&nbsp Xiaodan Chang, or Rachel</font>';

var CustomMenuSpacer='MenuSpacer.gif';
//CustomMenuSpacer='';
//CustomMenuSpacer='image';

//CustomMenuFixedWidth=false;
//CustomMenuFixedWidth=true;



///////////
//SetBlue Colors
CustomMenuNormalBgColor='';

CustomMenuCornerTL='corner_tl_333366.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_333366.gif';
CustomMenuCornerBR='corner_br_333366.gif';
CustomMenuCornerBL='corner_bl_333366.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuSelectColor='blue';
//CustomMenuNormalBgColor='';
CustomMenuCurrentColor='navy';
CustomMenuCurrentColor='gray';
CustomMenuCurrentColor='#666699';

CustomMenuNormalBgColor='#222255';
///////////

// NEW
CustomMenuCornerTL='corner_tl_white.gif';
//CustomMenuCornerTL='';
CustomMenuCornerTR='corner_tr_white.gif';
CustomMenuCornerBR='corner_br_white.gif';
CustomMenuCornerBL='corner_bl_white.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCornerTL='corner_tl_silver.gif';
CustomMenuCornerTR='corner_tr_silver.gif';
CustomMenuCornerBR='corner_br_silver.gif';
CustomMenuCornerBL='corner_bl_silver.gif';
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCurrentColor='#333366';

CustomMenuNormalBgColor='#666699';
CustomMenuNormalBgColor='#8888BB';


// NEW
CustomMenuText='';

CustomMenuCornerTL=PagesMenuCornerTL;
//CustomMenuCornerTL='';
CustomMenuCornerTR=PagesMenuCornerTR;
CustomMenuCornerBR=PagesMenuCornerBR;
CustomMenuCornerBL=PagesMenuCornerBL;
CustomMenuCornerBR='';
CustomMenuCornerBL='';

CustomMenuCurrentColor=PagesMenuCurrentColor;
CustomMenuNormalBgColor=PagesMenuNormalBgColor;
CustomMenuSelectColor=PagesMenuSelectColor;

CustomMenuLabelBefore=PagesMenuLabelBefore;
CustomMenuLabelAfter=PagesMenuLabelAfter;
CustomMenuAttributes=PagesMenuAttributes;


// /NEW



//alert(Menu.length);

// Do not display if it is framed
//if (window.top == window.self || window.self.name=='menu') {
if (window.top == window.self || window.self.name!='page') {

//if (MenuTop.length > 1) {
 document.write('<div id="MenuTopDiv">');
// alert(MenuTop.length);
 WriteMenu(MenuTop);
 document.write('</div>');
//};

// Do not display if it is framed
};


// Counter
//
//document.write('<br>');
//document.write('<table border="1"><tr><td>');
//document.write('<a href="http://escati.linkopp.net/counter2001/377661.shtml">');
//document.write('<img src="http://escati.linkopp.net/cgi-bin/counter2001.cgi?377661" alt="Escati counter" border="0">');
//document.write('</a>');
//document.write('</td></tr></table>');

// MenuF override

function GetURLFileName (URL) {
//var d,p,u,URLFileName;
var slash;
 if (URL.substring(0,7)=='file://') 
   { slash=URL.lastIndexOf('\\'); }
  else { slash=URL.lastIndexOf('/'); };
// slash=URL.lastIndexOf('/');
 URLFileName=URL.substring(slash + 1,URL.length);
 URLFileName=URLremoveParameters(URLFileName);
 if (URLFileName=='') URLFileName='index.asp';
 return (URLFileName);
// return URL.substring(slash + 1,URL.length);
};



