/**
 * --------------------------------------------------------------------------------------------------------------------------
 * FUNCIONAMIENTO DE COLUMNAS
 */
 
function leftFill() {
if (document.images) {
	 if (document.getElementById("leftcolfill").style.display != "block") {
	 		 document.getElementById("leftcolfill").style.display = "block";
} else {
	document.getElementById("leftcolfill").style.display = "none";
	document.getElementById("wrapper2").style.width = "auto";
	}
if (document.getElementById("wrapper2").style.width == "100%") {
document.getElementById("wrapper2").style.width = "auto";
  } else {
  	document.getElementById("wrapper2").style.width = "100%";
         }
}}

function rightFill() {
if (document.images) {
	 if (document.getElementById("rightcolfill").style.display != "block") {
	 		 document.getElementById("rightcolfill").style.display = "block";
			 document.getElementById("wrapper2").style.width = "100%";
} else {
	document.getElementById("rightcolfill").style.display = "none";
	document.getElementById("wrapper2").style.width = "auto";
	}
if (document.getElementById("wrapper2").style.width == "100%") {
document.getElementById("wrapper2").style.width = "auto";
  } else {
  	document.getElementById("wrapper2").style.width = "100%";
         }
}}


/**
 * --------------------------------------------------------------------------------------------------------------------------
 * _BLANK A VÍNCULOS EXTERNOS
 */

window.onload = function() {
	// check to see that the browser supports the getElementsByTagName method
	// if not, exit the loop
	if (!document.getElementsByTagName) {
		return false;
	}
	// create an array of objects of each link in the document
	var popuplinks = document.getElementsByTagName("a");
	// loop through each of these links (anchor tags)
	for (var i=0; i < popuplinks.length; i++) {
		if (popuplinks[i].className == "external") {
			// add an onclick event on the fly to open a new browser window
			popuplinks[i].onclick = function() {
			window.open(this.getAttribute("href"));
			return false;
		   }
		}
	}
}

