Ver Mensaje Individual
  #1 (permalink)  
Antiguo 29/11/2004, 12:33
Avatar de Chuty
Chuty
 
Fecha de Ingreso: noviembre-2002
Ubicación: el bar de la esquina
Mensajes: 609
Antigüedad: 21 años, 6 meses
Puntos: 2
problema con target

Buenas, tengo el siguiete problema, con un formulario.
por ejemplo cuando le doy Aplicar me da un error.
A Runtime Error has occurred.
Do you wish to Debug?
Line:5
Error:'this.form' is null or not an object


Este es mi codigo de ejemplo.


Código PHP:
<form method="POST" name="formul" action="Adm_dev1.php?<? echo SID ?>">
  <input type="submit" value="Vista Previa" onclick="this.form.target = 'popup'; this.form.action = 'Adm_hwo.php?<? echo SID ?>'; this.form.method = 'POST'; window.open('', 'popup', 'width=400,height=450')" style="font-size: 8 pt"> 
  <input type="submit" value="  Aplicar   " onclick="this.form.target = ''; this.from.action = 'Adm_dev1.php'; this.form.method = 'POST';">
</form>
El por que tengo un this.form.target en el submit del Aplicar, es porque si presiono primero el boton de Vista Previa y luego Aplicar me abria una nueva ventana. y el Boton de Aplicar no me debe abrir una nueva ventana.

Desde ya muchas gracias y saludos a todos