/*  

 This file is a template file for setting of Vertical Navigation Bars

  The Vertical bar setting is done by initializing values into the pre defined barArray  in NavGen: :    
        - bar Array  is used and  is initialized for VERTICAL  bar  images  from loaction 0 up-to  30
        - bar Array  is used and  is initialized for HORIZONTAL  bar images in from location 31 up-to  60

   the declaration in NavGen.js is  
            var horPtr = 30 ;       // the location and the allocation  of the Horizontal bars starts in barAry at location 31
                                               //    therefore we set the horPtr as 30     
          barArray = new Array(horPtr +30);  // create global barArray to store images for verical and horizontal bars
                                                                  //  this is equal to say BarArray = new Array(60 ); 

*/  

/*  Set the array of icons
     for each image in the Vertical navigator bar, replace the corresponding
     image source files and the corresponding link file/url
*/  

//-----------------------------------------------------------------

// NavClass Method - function setBarArray()
//         creates bar instances with correct settings for each bar in Vertical navagation bar
//-----------------------------------------------------------------

function setBarArray()	

{	

  barArray[1] = new BarClass(1,"research", 

                 "/materials/tenne/images/btn_res1.gif",  //default image file
	             "/materials/tenne/images/btn_res2.gif",  //image for mouseOn
                 "/materials/tenne/images/btn_res3.gif",  //image for selected category 
                  "/materials/tenne/research.html",     //the link for bar#1
                 "Research");   //alt tag    
	  

// barArray[2] = new BarClass(2,"publications",  

         //     "/materials/tenne/images/btn_pub1.gif",   
	     //    "/materials/tenne/images/btn_pub2.gif",
         //     "/materials/tenne/images/btn_pub3.gif",
		//      "/materials/tenne/publications.pdf", 
       //       "Publications");



 barArray[2]= new BarClass(2,"cv",  

              "/materials/tenne/images/btn_cvnew1.gif",
		      "/materials/tenne/images/btn_cvnew2.gif",
		      "/materials/tenne/images/btn_cvnew3.gif", 
		      "/materials/tenne/cv.pdf",
              "CV");



	 barArray[3]= new BarClass(3,"links",  

              "/materials/tenne/images/btn_links1.gif",
		      "/materials/tenne/images/btn_links2.gif",
		      "/materials/tenne/images/btn_links3.gif", 	 
	   	     "/materials/tenne/links.html",
              "Links");

	
	 barArray[4]= new BarClass(4,"home",  

              "/materials/tenne/images/btn_home1.gif",
		      "/materials/tenne/images/btn_home2.gif",
		      "/materials/tenne/images/btn_home3.gif", 
		      "/materials/tenne/home.html",
              "Home");

	
}	


//-----------------------------------------------------------------
// function initNav(): Set the parameter numOfBars to total number of the Vertical bars (icon-images)
//-----------------------------------------------------------------

function initNav() { 

  var numOfBars= 4 ;

  var  topHtml='';

  var  botHtml=' ';



topHtml += '<table width="100%"  border="0" cellspacing="0" cellpadding="0">' ;

topHtml += '<tr><td width="207" align="left" valign="top">' ;  

topHtml += '<table width="207"  border="0" cellspacing="0" cellpadding="0" >' ;

 topHtml += '<tr><td height="63" align="left" valign="top"><img src="/materials/tenne/images/nav_top.gif" width="207" height="63"></td></tr>' ;

  
botHtml += '<tr><td height="25" width="207" align="left" valign="top" background="/materials/tenne/images/bc_nav.gif"><img src="/materials/tenne/images/bc_nav.gif" width="207" height="25"></td></tr>' ;
botHtml += '<tr><td height="67" width="207" align="left" valign="top"><img src="/materials/tenne/images/nav_bot.gif" width="207" height="67"></td></tr>' ;
botHtml += '</table></td>' ;    

botHtml += '<td align="left" valign="top" height="100%">';	 

  

 theNav= new NavClass(numOfBars, topHtml, botHtml);  //the parameter - number of the bars in the navagation bar 

  setBarArray();             //fill barAray with images          //fill barAray with images

}

 



function writeHeader() {
document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0" height="146"><tr>');
  

document.write('<td width="207" height="146" align="left" valign="top" rowspan="3"><img src="/materials/tenne/images/logo.jpg" width="207" height="146"></td>');
document.write('<td width="112" height="100" align="left" valign="top"><img src="/materials/tenne/images/log2.jpg" width="112" height="100"></td>');
document.write('<td width="100%" height="100" align="left" valign="top" background="/materials/tenne/images/bc_blue.jpg"><img src="/materials/tenne/images/title.gif" width="324" height="100"></td>');
 document.write('<td width="280" height="100" align="right" valign="top" background="/materials/tenne/images/bc_blue.jpg"><a href="/"><img src="/materials/tenne/images/wis.gif" width="280" height="100" border="0"></a></td>');
document.write('</tr><tr>');
document.write('<td width="112" height="23" align="left" valign="top"><img src="images/logo22.jpg" width="112" height="23"></td>');
document.write('<td height="23" align="left" valign="top" background="/materials/tenne/images/pc_line.gif"><img src="images/pc_line.gif" width="94" height="23">');document.write('</td>');
document.write('<td width="280" height="23" align="right" valign="top" ><a href="/materials/"><img src="/materials/tenne/images/dept.gif" width="280" height="23" border="0"></a></td>');
document.write('</tr><tr>');    
document.write('<td height="23" colspan="3" align="left" valign="top"><img src="/materials/tenne/images/group.gif" width="240" height="23"></td>');
document.write('</tr><tr>');    
document.write('<td height="54" colspan="4" align="left" valign="top"><img src="/materials/tenne/images/logo11.jpg" width="207" height="54"></td>');

document.write('</tr></table>');


}



function writeFooter() {

document.write ('<hr>');
document.write ('<blockquote>');
document.write ('<center>');
document.write('<font size="-1">Comments and Suggestions: <a href="mailto:reshef.tenne@weizmann.ac.il?subject=Tenne web site">reshef.tenne@weizmann.ac.il</font></a>');
document.write('<br>');
document.write('<font size="-1">Last Updated: ');
document.write (document.lastModified);
document.write('</font>');
document.write ('</center>');
document.write ('</blockquote>');

}



//Closes the table for teh navigation bar

function closeAll() {

document.write('</td></tr></table>');



  }	

