/* This file contains most of the pieces necessary to control the rollover effect. It is likely you may	need to make adjustments to this file based on your needs. *//* This piece determines if a Netscape 4x browser is being used. This is needed because layers are used in the	HTML templates and Netscape 4x browsers reference images in layers slightly differently than other browsers,	so this must be compensated for. It is recommend that this is not changed.*/NS4 = false;if ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) == 4)) {	NS4 = true;}/* This next section preloads graphics used for the rollovers.	Each set of four lines represents one button. The first two lines are the button's "off" state and the second two	represent the buttons "on" state. The second and fourth lines designate the graphic file to be used for the off	and on states respectively.	The name given for the button in the HTML file is used here with the suffix "off" and "on".	For example, this line is taken from the global navigation:	<A HREF="#" onMouseover="turnon('button1')" onMouseout="turnoff('button1')">		<IMG NAME="button1" SRC="images/button_off.gif" ALT="Button name here" BORDER="0">	</A>	The image's name is defined by the NAME attribute. In this case, NAME="button1". Notice also that the name button1 is	used in the function call for "onMouseover" and "onMouseout". This tells the script which button to affect.		For the purposes of the global navigation, there are six definitions - one for each button. It is recommended that	you simply change the graphics files referenced instead of all the names. If using less than 6 buttons, comment out	the ones not used. There are two kinds of JavaScript comments: block comments, like the one used for this comment,	and line comments: ( // ). Line comments affect only text to the right of the comment tag to the end of the line.	Block comments affect everything between the opening and closing tags.	*/	button1off = new Image();	button1off.src = "assets/icon_portafolio.gif";	button1on = new Image();	button1on.src = "assets/icon_portafolio_on.gif";	button2off = new Image();	button2off.src = "images/tab_servicios.gif";	button2on = new Image();	button2on.src = "images/tab_apagado.gif";	button3off = new Image();	button3off.src = "images/tab_publicaciones.gif";	button3on = new Image();	button3on.src = "images/tab_apagado.gif";	button4off = new Image();	button4off.src = "images/tab_planificacion.gif";	button4on = new Image();	button4on.src = "images/tab_apagado.gif"; 	button5off = new Image();	button5off.src = "images/tab_corpovargas.gif";	button5on = new Image();	button5on.src = "images/tab_apagado.gif";/*	button6off = new Image();	button6off.src = "images/button_off.gif";	button6on = new Image();	button6on.src = "images/button_on.gif";   *//* The next two image sets affect the arrows in the local navigation section of the subpage. If not using the local	navigation, simply comment these out. If using the local navication, and you need to add more links, follow the	directions in the subpage_template.html for adding more links. Then, change the NAME attribute for the newly added	arrow images. It is recommended to keep with the sequential numbering of the word "arrow". Next, copy a set of	rollover definitions below and paste at the end of the list of arrow definitions. Change the name of the new	definitions based on the names used for the new links, but also keeping the suffixes "off" and "on". You do not	need to change the image file name.*/	arrow1off = new Image();	arrow1off.src = "images/arrow_off.gif";	arrow1on = new Image();	arrow1on.src = "images/arrow_on.gif";	arrow2off = new Image();	arrow2off.src = "images/arrow_off.gif";	arrow2on = new Image();	arrow2on.src = "images/arrow_on.gif";	arrow3off = new Image();	arrow3off.src = "images/arrow_off.gif";	arrow3on = new Image();	arrow3on.src = "images/arrow_on.gif";	arrow4off = new Image();	arrow4off.src = "images/arrow_off.gif";	arrow4on = new Image();	arrow4on.src = "images/arrow_on.gif";//FUNCTIONS/* The following two functions control the image swap necessary for the rollover effect. It is not recommended that	these be changed unless you are familiar with how image rollover scripts work.*/function turnon(i, whichLayer) {	if (NS4 && whichLayer) {		document.layers[whichLayer].document.images[i].src = eval(i + "on.src");	} else {		document.images[i].src = eval(i + "on.src");	}}function turnoff(i, whichLayer) {	if (NS4 && whichLayer) {		document.layers[whichLayer].document.images[i].src = eval(i + "off.src");	} else {		document.images[i].src = eval(i + "off.src");	}}//FUNCTIONS Random Image/* The following functions handle the image in the main menu and any other image that you want to make random in the site*/var onImages = new Array();      var cont = -1;      var browserName = navigator.appName;      var browserVer = parseInt(navigator.appVersion);      if (browserName == "Netscape" && browserVer >= 3) version = "n3";          else if (browserName == "Netscape" && browserVer <= 2) version = "n2";          else if (browserName == "Microsoft Internet Explorer" && browserVer > 3) version = "e4";          else if (browserName == "Microsoft Internet Explorer" && browserVer <= 3) version = "e3";          else version = "other";function ranNum( lowLim, hiLim ) {	if (version == "n3" | version == "e4")                { 	for ( var rdmNum = Math.random();  	rdmNum < 0.1; rdmNum=rdmNum * 10 ) {}   	var normalVal = (hiLim-lowLim) * rdmNum; 	return Math.ceil( normalVal ) + lowLim;	}	}     			function  ranIma(com,fine,direc,tipo){		if (version == "n3" | version == "e4")                {	url="";	var imaz= ranNum(com,fine);	url = "images/"+direc+"/" + imaz + "." + tipo;	document[direc].src = url;		}	}	