function isBlank( cArg )
{
while ( cArg.length > 0 && cArg.charAt( cArg.length - 1 ) == " " ) {
	cArg = cArg.substring( 0, cArg.length - 1 );
	}
return cArg == "";
}

function gestioneTasti(form) {
    if (event.keyCode == 13) {
        // istruzioni per la gestione del tasto
        convalida(form)
        // istruzioni per prevenire il propagarsi dell'evento
        event.keyCode = 0
        event.returnValue = false
        event.cancelBubble = true
        return false
    }
}

function convalida(form) {
if (isBlank(form.term.value)) {
		form.term.focus()
		//alert("Inserire un termine")
		return
	}
	form.submit()
}

function mostra(oggetto) {
	if (oggetto.style.display == "none") {
		oggetto.style.display = "block"
	} else {
		oggetto.style.display = "none"
	}
}


