<!--


function preimg()
{

	imatges=new Array();
	if (document.images!=null)
	{
		for (field in document.images)
		{
			if (!isNaN(field) && field!="length")
			{
			imatges[field]=new Image();
			imatges[field].src="/home/fototeca/imatges/"+document.images[field].name+"on.gif";
			}
		}
	}	

}

function encen(boto,bit)
{
if (document.images!=null){

if (bit==1)
{ // encén botó 

 nouboto="/home/fototeca/imatges/"+boto+"on.gif";


}
else
{// apaga botó 

 nouboto="/home/fototeca/imatges/"+boto+"off.gif";

}
document.images[boto].src=nouboto ;
}
}


function cerca(text)
{
	document.forma.T.value=text;
	aux=document.forma.CERCA.value;
	aux2=aux;
	aux2=aux2.split(/ */);
	
	if (aux2.length!=0 && aux!=""  )
		document.forma.submit();
	else
	alert("Heu d'introduir algun criteri abans d'efectuar la cerca.");
}

function neteja(num) {

if (num==0)
	document.formf.LIN.selectedIndex=-1;
else
	document.formf.TX.selectedIndex=-1;
	return false;

}
function seleccio()
{document.formf.submit();
}
function remet(vcbd,vndc,vtipus,vtext)
{
	var prefix="";
	var remSufix="";

	if (vtipus=="")
		vtipus="2";

	prefix="<i>";
	remSufix="</i>";

	document.write(prefix);


	document.write(vtext);
	document.write(remSufix);
}



//-->

