
function bCategoria(dato) {
	document.getElementById("cat").value = dato;
	document.getElementById("sec").value = 0;
	document.getElementById("pro").value = 0;
	document.busca.submit();
}

function bSector(dato) {
	document.getElementById("sec").value = dato;
	document.getElementById("pro").value = 0;
	document.busca.submit();
}

function bProducto(dato) {
	document.getElementById("pro").value = dato;
	document.busca.submit();
}

function highlight(event) {
	this.style.backgroundColor='#DEE9FF';
	this.style.borderBottomColor='#C0C0C0';
	//this.style.letterSpacing='2px';
	//this.style.paddingLeft='10px';
	//this.style.listStyleType='square';
	this.style.listStyleImage='url(/img/ok2.gif)';
	//this.style.paddingTop='0px';
	//this.style.paddingBottom='6px';
	//this.style.textAlign='right';
	this.style.cursor='pointer';
}

function normal(event) {
	this.style.backgroundColor='#F3F3F3';
	this.style.borderBottomColor='#094EA3';
	//this.style.letterSpacing='1px';
	//this.style.paddingLeft='5px';
	//this.style.listStyleType='none';
	this.style.listStyleImage='none';
	//this.style.paddingTop='4px';
	//this.style.paddingBottom='2px';
	this.style.cursor='auto';
}

function redir(event) {
	document.location.href = this.firstChild.href;
}

function menu() {
	var z = document.getElementById("menuitems").getElementsByTagName("li").length;
	for (var i=1; i<=z; i++ ) {
		document.getElementById('menu'+i).onmouseover = highlight;
		document.getElementById('menu'+i).onmouseout  = normal;
		document.getElementById('menu'+i).onclick = redir;
	}
}

function CreateControlFlash(divid, objectid, width, height, url, mode) {
	var d = document.getElementById(divid);
	var strHTML = '<object id="' + objectid + '" type="application/x-shockwave-flash" data="' + url + '" width="' + width + '" height="' + height + '">';
	strHTML = strHTML + '<param name="movie" value="' + url + '" />';
	if(mode=='1') { strHTML = strHTML + '<param name="wmode" value="transparent" />'; }
	strHTML = strHTML + '<a href="http://www.macromedia.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash&amp;Lang=Spanish&amp;P5_Language=Spanish"><img src="flash/noflash.gif" border="0" alt="no tiene flash" /></a>';
	strHTML = strHTML + '</object>';
	d.innerHTML = strHTML;
}

function MailLink (usuario, dominio, tld) {
	 //codifica los caracteres mas significativos
	 var arroba = '@'
	 var punto = '.'
	
	 //utiliza variables para ocultar las palabras clave
	 var etiqueta = 'ma' + '' + 'il'
	 var dospuntos = 'to:'
	 var localizador = usuario
	 localizador = localizador + arroba + dominio;
	 localizador = localizador + punto + tld;
	
	 //escribe en enlace
	 document.write('<a href="' + etiqueta + dospuntos + localizador + '">' + localizador + '</a>');
}

function MailLinkImg (usuario, dominio, tld, src) {
	 //codifica los caracteres mas significativos
	 var arroba = '@'
	 var punto = '.'
	
	 //utiliza variables para ocultar las palabras clave
	 var etiqueta = 'ma' + '' + 'il'
	 var dospuntos = 'to:'
	 var localizador = usuario
	 localizador = localizador + arroba + dominio;
	 localizador = localizador + punto + tld;
	
	 //escribe en enlace
	 document.write('<a href="' + etiqueta + dospuntos + localizador + '">' + '<img src="' + src + '" alt="Email" border="0" align="right" />' + '</a>');
}

// Script Source: CodeLifter.com
// Copyright 2003
// Do not remove this notice.

// SETUPS:
// ===============================

// Set the horizontal and vertical position for the popup

PositionX = 50;
PositionY = 50;

// Set these value approximately 20 pixels greater than the
// size of the largest image to be used (needed for Netscape)

defaultWidth  = 500;
defaultHeight = 500;

// Set autoclose true to have the window close automatically
// Set autoclose false to allow multiple popup windows

var AutoClose = true;

// Do not edit below this line...
// ================================
if (parseInt(navigator.appVersion.charAt(0))>=4){
var isNN=(navigator.appName=="Netscape")?1:0;
var isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}
var optNN='scrollbars=no,width='+defaultWidth+',height='+defaultHeight+',left='+PositionX+',top='+PositionY;
var optIE='scrollbars=no,width=150,height=100,left='+PositionX+',top='+PositionY;

function popImage(imageURL,imageTitle){
if (isNN){imgWin=window.open('about:blank','',optNN);}
if (isIE){imgWin=window.open('about:blank','',optIE);}
with (imgWin.document){
writeln('<html><head><title>Loading...</title><style>body{margin:0px;}</style>');writeln('<sc'+'ript>');
writeln('var isNN,isIE;');writeln('if (parseInt(navigator.appVersion.charAt(0))>=4){');
writeln('isNN=(navigator.appName=="Netscape")?1:0;');writeln('isIE=(navigator.appName.indexOf("Microsoft")!=-1)?1:0;}');
writeln('function reSizeToImage(){');writeln('if (isIE){');writeln('window.resizeTo(300,300);');
writeln('width=300-(document.body.clientWidth-document.images[0].width);');
writeln('height=300-(document.body.clientHeight-document.images[0].height);');
writeln('window.resizeTo(width,height);}');writeln('if (isNN){');       
writeln('window.innerWidth=document.images["George"].width;');writeln('window.innerHeight=document.images["George"].height;}}');
writeln('function doTitle(){document.title="'+imageTitle+'";}');writeln('</sc'+'ript>');
if (!AutoClose) writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()">')
else writeln('</head><body bgcolor=000000 scroll="no" onload="reSizeToImage();doTitle();self.focus()" onblur="self.close()">');
//writeln('<img name="George" src="'+imageURL+'" style="display:block"></body></html>');
writeln('<img name="George" src="_thumbs.php?imagen='+imageURL+'&factor=1" style="display:block"></body></html>');
close();		
}}

window.onload = menu;