Ver Mensaje Individual
  #2 (permalink)  
Antiguo 06/03/2008, 08:25
Avatar de ZiTAL
ZiTAL
 
Fecha de Ingreso: marzo-2004
Ubicación: Bermio (Bizkaia)
Mensajes: 1.545
Antigüedad: 20 años, 11 meses
Puntos: 62
De acuerdo Re: detener submit

si el boton es un tipo submit ahi esta el problema:

Solucion nº1: poner el input type como button.
Solucion nº2: poner un onsubmit al formulario:

<form onsubmit="return pregunta(this)"...
...
Código:
function pregunta(esto){
if (confirm('¿Estas seguro de enviar este formulario?'))
{
return true;
}
else
{
alert ('no sera enviado');
return false;

}
}
__________________
http://zital.no-ip.org
____________________

Euskerie ahuen eta bijotzan