Comunidad de diseño web y desarrollo en internet online

dos formularios + php

Citar            
MensajeEscrito el 20 May 2006 02:11 am
como tener dos formularios en php y enviarlos meidenta HTTP_POST_VARS

Por juan_gv

108 de clabLevel



 

firefox
Citar            
MensajeEscrito el 20 May 2006 03:45 pm
fon dos <form method="POST">
un saludo

Por fael

BOFH

2443 de clabLevel

3 tutoriales
2 articulos

 

firefox
Citar            
MensajeEscrito el 21 May 2006 05:02 am
quiero q salga unos avisos de gracias por el formulario independientemenete

Por juan_gv

108 de clabLevel



 

firefox
Citar            
MensajeEscrito el 21 May 2006 03:41 pm

Código :

<?
if(count($_POST)){
echo "gracias";
}
?>

Por fael

BOFH

2443 de clabLevel

3 tutoriales
2 articulos

 

firefox
Citar            
MensajeEscrito el 22 May 2006 09:29 pm

Por juan_gv

108 de clabLevel



 

firefox
Citar            
MensajeEscrito el 23 May 2006 12:22 am
erghh no se envian lo dos, prueba este codigo y veras

Código :

<div align="left">
<form id="form1" name="form1" method="post" action="">
  <label>
  <input type="text" name="textfield" />
  </label>
  <label>
  <input type="submit" name="Submit" value="Submit" />
  </label>
</form>
</div>
<div align="right">
<form id="form2" name="form2" method="post" action="">
  <label>
  <input type="text2" name="textfield2" />
   <input type="submit" name="Submit2" value="Submit" />
  </label>
</form>
</div>
<?php
   if (isset($_POST["Submit2"])){
      echo "enviaste el segundo formulario";
      print_r($_POST);
   }
   if (isset($_POST["Submit"])){
      echo "enviaste el primer formulario";
      print_r($_POST);
   }
?>

Por Maikel

BOFH

5575 de clabLevel

22 tutoriales
5 articulos

Genero:Masculino   Team Cristalab

Claber de baja indefinida

firefox
Citar            
MensajeEscrito el 01 Jun 2006 01:50 am
Lo que pasa es q quiero poner en vez de los inputs normales imagenes para enviar pero no se si sera por eso q no me sale a ver por fa ayuda
mira mi codigo
<div align="left">
<form id="form1" name="form1" method="post" action="a la misma pagina">
<label> <input type="text" name="textfield" /> </label>
<a class="enlace" href="#" name="Submit1" onClick="document.forms.form1.submit();return false"><img src="imagenes/but1.jpg" name="Submit1" width="120" height="18" border="0" alt="enviar"></a>
</form>
</div>
<div align="right">
<form id="form2" name="form2" method="post" action="a la misma pagina">
<label>
<input type="text2" name="textfield2" />
<a class="enlace" href="#" name="Submit2" onClick="document.forms.form1.submit();return false"><img src="imagenes/but1.jpg" name="Submit2" width="120" height="18" border="0" alt="enviar"></a>
</label>
</form>
</div>
<?php if (isset($_POST["Submit2"]))
{ echo "enviaste el segundo formulario";
print_r($_POST); }
if (isset($_POST["Submit"]))
{ echo "enviaste el primer formulario";
print_r($_POST);
}?>

Por juan_gv

108 de clabLevel



 

msie

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.