Foros del Web » Programando para Internet » PHP »

Ayuda Programar Boton Php Para Formulario Html!

Estas en el tema de Ayuda Programar Boton Php Para Formulario Html! en el foro de PHP en Foros del Web. HOLA, COMO HOBBIE ESTOY HACIENDO LA PAGINA DE UN EMPRENDIMIENTO QUE TENGO ME GUSTARIA QUE ME AYUDARAN CON ESTO YA QUE ME ESTOY VOLVIENDO LOCO! ...
  #1 (permalink)  
Antiguo 02/06/2008, 10:59
 
Fecha de Ingreso: junio-2008
Mensajes: 7
Antigüedad: 15 años, 11 meses
Puntos: 0
Ayuda Programar Boton Php Para Formulario Html!

HOLA, COMO HOBBIE ESTOY HACIENDO LA PAGINA DE UN EMPRENDIMIENTO QUE TENGO ME GUSTARIA QUE ME AYUDARAN CON ESTO YA QUE ME ESTOY VOLVIENDO LOCO!



les pongo el codigo HTML de mas esta decir que le pongo mucha garra para hacer la pagina lei un monton de foros pero con esto me estoy volviendo mongui!...

<form action="send.php" method="post" name="form1" target="_blank">
<table width="652" border="1" cellpadding="0" cellspacing="0" id="formtabla">
<tr>
<td colspan="2" align="left" valign="top"><div align="center"><span class="Estilo1">FORMULARIO DE COMPRA</span></div></td>
</tr>
<tr>
<td width="226" align="left" valign="top"><span class="Estilo4">NOMBRE Y APELLIDO</span></td>
<td width="420"><input name="NOMBRE Y APELLIDO" type="text" id="NOMBRE Y APELLIDO" title="NOMBRE Y APELLIDO" dir="ltr" lang="es" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">E-MAIL</span></td>
<td><input name="E-MAIL" type="text" id="E-MAIL" title="E-MAIL" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">TELEFONO DE LINEA </span></td>
<td><input name="TELEFONO DE LINEA" type="text" id="TELEFONO DE LINEA" title="TELEFONO DE LINEA" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">CELULAR</span></td>
<td><input name="TELEFONO MOVIL" type="text" id="TELEFONO MOVIL" title="TELEFONO MOVIL" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">DIRECCION DE ENTREGA </span></td>
<td><input name="DIRECCION DE ENTREGA" type="text" id="DIRECCION DE ENTREGA" title="DIRECCION DE ENTREGA" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">HORARIO DE ENTREGA</span></td>
<td><input name="HORARIO DE ENTREGA" type="text" id="HORARIO DE ENTREGA" title="HORARIO DE ENTREGA" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">LOCALIDAD, PROVINCIA</span></td>
<td><input name="LOCALIDAD Y PROVINCIA" type="text" id="LOCALIDAD Y PROVINCIA" title="LOCALIDAD Y PROVINCIA" size="70"></td>
</tr>
<tr>
<td align="left" valign="top" class="Estilo4">CODIGO POSTAL</td>
<td><input name="CODIGO POSTAL" type="text" id="CODIGO POSTAL" title="CODIGO POSTAL" size="70"></td>
</tr>
<tr>
<td align="left" valign="top"><span class="Estilo4">FORMA DE PAGO </span></td>
<td><select name="FORMA DE PAGO" id="FORMA DE PAGO">
<option>Efectivo contra entrega</option>
<option>Deposito Bancario</option>
<option>Pago Por dinero Mail</option>
</select>
<span class="Estilo4"><a href="pagoyenvio.txt">LEE LAS POLITICAS DE PAGO Y ENVIO</a></span></td>
</tr>
<tr>
<td align="left" valign="middle"><span class="Estilo4">PRODUCTO</span></td>
<td><select name="select" size="1">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
<input name="textfield" type="text" disabled="true" value="Stereo Pioneer 5000ub $ 740 + ENVIO" size="62" readonly="true"></td>


el codigo PHP es el siguiente lo saque de internet.

<?
$remitente = $_REQUEST["E-MAIL"];
$mensaje = $_REQUEST"NOMBRE Y APELLIDO";

mail("[email protected]", "NUEVA VENTA DESDE DP", $mensaje, "From: $remitente");
?>

que es lo que me falta!?... me gustaria que todo el formulario completo me aparezca en el mail. Y TAMBIEN QUE LUEGO DE HABER PUESTO ENVIAR QUE SE HABRA UN POP UP PEQUEÑO CON CON UNA IMAGEN AGRADECIENDO!.


Gracias por la ayuda que me puedan brindar!.... Slds.
  #2 (permalink)  
Antiguo 02/06/2008, 11:08
Avatar de pateketrueke
Modernizr
 
Fecha de Ingreso: abril-2008
Ubicación: Mexihco-Tenochtitlan
Mensajes: 26.399
Antigüedad: 16 años
Puntos: 2534
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

bueno... ayuda mucha, pero aqui el que quiere azul celeste.... que le cueste

noto, por tu manera de programar... que si es un hobbie, aun asi.... deberias leerte un manual basico de PHP .... ya que lo que pides es simple....

por cierto ¿¿esta linea no te da error???

Cita:
$mensaje = $_REQUEST"NOMBRE Y APELLIDO";
PDTA: tambien necesitas una leidita de HTML basico.... ya que NO esta permitido el uso de espacios en los atributos de ID/NAME ... animo! (quiza ese... tambien sea un error)
__________________
Y U NO RTFM? щ(ºдºщ)

No atiendo por MP nada que no sea personal.
  #3 (permalink)  
Antiguo 02/06/2008, 11:55
 
Fecha de Ingreso: junio-2008
Mensajes: 7
Antigüedad: 15 años, 11 meses
Puntos: 0
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

Cita:
Iniciado por pateketrueke Ver Mensaje
bueno... ayuda mucha, pero aqui el que quiere azul celeste.... que le cueste

noto, por tu manera de programar... que si es un hobbie, aun asi.... deberias leerte un manual basico de PHP .... ya que lo que pides es simple....

por cierto ¿¿esta linea no te da error???



PDTA: tambien necesitas una leidita de HTML basico.... ya que NO esta permitido el uso de espacios en los atributos de ID/NAME ... animo! (quiza ese... tambien sea un error)
GRACIAS POR TU APORTE, LE CAMBIE ESO Y AL MENOS AHORA ME ENVIA EL NOMBRE Y EL APELLIDO, COMO HAGO PARA QUE ME AGREGUE ADEMAS DEL NOMBRE Y APELLIDO LOS DATOS DE TODOS LOS CAMPOS DEL FORMULARIO, EL FINDE VOY A LEER UNA GUIA, PERO ME GUSTARIA RESOLVERLO AHORA LO DEL BOTONCITO,
1000 GRACIAS, Y TENGO LOS OJOS BIEN ABIERTOS PARA LEER CUALQUIER OTRO APORTE. SLDS.
  #4 (permalink)  
Antiguo 02/06/2008, 12:05
Avatar de pateketrueke
Modernizr
 
Fecha de Ingreso: abril-2008
Ubicación: Mexihco-Tenochtitlan
Mensajes: 26.399
Antigüedad: 16 años
Puntos: 2534
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

como te das cuenta... $mensaje guarda el mensaje que estas enviando... simplement ya viste como obtener las variables a traves de un FORM... lo demas es mas simple....

has por ejemplo...

$mensaje .= $mas_datos;
$mensaje .= $mas_datos;
$mensaje .= $mas_datos;

NOTA: el .= que es el operador de concatenacion, bueno... suerte!
__________________
Y U NO RTFM? щ(ºдºщ)

No atiendo por MP nada que no sea personal.
  #5 (permalink)  
Antiguo 02/06/2008, 13:08
 
Fecha de Ingreso: junio-2008
Mensajes: 7
Antigüedad: 15 años, 11 meses
Puntos: 0
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

Cita:
Iniciado por pateketrueke Ver Mensaje
como te das cuenta... $mensaje guarda el mensaje que estas enviando... simplement ya viste como obtener las variables a traves de un FORM... lo demas es mas simple....

has por ejemplo...

$mensaje .= $mas_datos;
$mensaje .= $mas_datos;
$mensaje .= $mas_datos;

NOTA: el .= que es el operador de concatenacion, bueno... suerte!
el codigo me quedo asi:

<?
$remitente = $_REQUEST["E-MAIL"];
$mensaje = $_REQUEST["NOMBRE"];
$mensaje .= $_REQUEST["TELEFONO"];
$mensaje .= $_REQUEST["MOVIL"];
$mensaje .= $_REQUEST["ENTREGA"];
$mensaje .= $_REQUEST["HORARIO"];
$mensaje .= $_REQUEST["LOCALIDAD"];
$mensaje .= $_REQUEST["POSTAL"];
$mensaje .= $_REQUEST["PAGO"];
$mensaje .= $_REQUEST["select2"];
$mensaje .= $_REQUEST["ARTICULO"];

mail("[email protected]", "NUEVA VENTA DESDE DP", $mensaje, "From: $remitente");
?>
  #6 (permalink)  
Antiguo 02/06/2008, 13:10
 
Fecha de Ingreso: junio-2008
Mensajes: 7
Antigüedad: 15 años, 11 meses
Puntos: 0
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

perdon me comi el .= aca $mensaje = $_REQUEST["NOMBRE"]; pero de todos modos sigue sin funcionar, solo me envia la primer linea que es el "nombre"
Algun consejo?
  #7 (permalink)  
Antiguo 02/06/2008, 15:30
Avatar de pateketrueke
Modernizr
 
Fecha de Ingreso: abril-2008
Ubicación: Mexihco-Tenochtitlan
Mensajes: 26.399
Antigüedad: 16 años
Puntos: 2534
Respuesta: Ayuda Programar Boton Php Para Formulario Html!

esta bien... yo me equivoque, el primer = es sin punto...

$mensaje = $datos;
$mensaje .= $mas_datos;
$mensaje .= $mas_datos;

estas en lo correcto... pero, seguro que lo tiene escrito asi... me parece bien!... aunque puedo decirte que lo que captura del <input/> es name="nombre_de_variable_no_id" mas o menos... por eso de que no es un ID como tal, sino el nombre de entrada/indice/variable o algo asi,....
__________________
Y U NO RTFM? щ(ºдºщ)

No atiendo por MP nada que no sea personal.
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 07:23.