sin reirse por fa!!!

From: Date: Wed, 27 Mar 2002 22:56:43 +0000
Subject: sin reirse por fa!!!
Groups: php.general.es 
Request: Send a blank email to general-es+get-20880@lists.php.net to get a copy of this message
wolas: estoi haciendo un formulario de reserva, pero tengo un error, el mensaje es el siguiente: Warning: Undefined variable: enviar in reserva.php on line 32 y según yo, la tengo definida!!! Pueden ver mi código y decirme que pasé por alto??? <HTML><HEAD><TITLE>HotelSoft - Formulario de Reserva de Habitaciones</TITLE> <META content="text/html; charset=windows-1252" http-equiv=Content-Type> <META <TABLE border=0 cellPadding=10 cellSpacing=0 width=600> <BODY background = imagenes/57.jpg> <TBODY> <TR> <TD colSpan=2> <P><!--menu ctxt--> <CENTER><FONT size=-1>[ <A href="index.html">Principal/Main </A> | <A ]</FONT></CENTER> <P><!--/menu ctxt--></P></CENTER></TD></TR> <TR> <P></P></TD></TR> <?php if ($enviar == "Enviar / Send"){ $link = mysql_connect("localhost", "nobody") or die ("No se puede conectar a la base de datos"); mysql_select_db("hotel", $db); $sql = "INSERT INTO reserva (nom_cli, fono_cli, fax_cli, email_cli, nom_emp, cif_emp, dir_emp, ciudad_emp, fono_emp, fax_emp, email_emp, met_conf_res) VALUES (´$nombre,´$telefono,´$fax,´$email,´$empresanombre,´$cif,´$direccion`,´$em presatelefono,´$empresafax,´$empresaemail,´$contactby)"; $result = mysql_query ($sql); echo "Se han recibido sus datos satisfactoriamente.\n"; } else{ ?> <FORM method="post" action="reserva.php"> <CENTER> <TR> <TD vAlign=top width="50%"><FONT face=arial>Nuestro <B>FORMULARIO DE RESERVA</B> es la forma más sencilla de solicitar información o una reserva de su habitación de manera detallada y con comodidad. Le recordamos que con este formulario usted realiza una <B>solicitud</B>, que deberá serle confirmada por el método que desee para que se considere efectiva. <P>Apreciamos todos sus comentarios, de manera que no dude en utilizar la última sección del formulario para hacernos llegar sus sugerencias, dudas, comentarios, etc. Gracias. <P></P></FONT></TD> <TD vAlign=top width="50%"><FONT color=#666666 face=arial>Our <B>RESERVATION FORM</B> lets you easily <B>request information</B> about the services and availability of our rooms and suites. Remember that if you use this form to <B>place a reservation</B>, it will be confirmed by phone by our staff. <P>We appreciate your comments, so feel free to use the space at the end of this form to send us your suggestions, inquiries or comments. Thank you.</FONT> <P></FONT></P></TD></TR> <TR> <TD vAlign=top width="50%"> <TABLE border=0 cellPadding=1 cellSpacing=0> <TBODY> <TR> <TD colSpan=2><B>Datos Personales / <FONT color=#666666>Personal Data</FONT></B> <P></P></TD></TR> <TR> <TD>Nombre/<FONT color=#666666>Name</FONT>:</TD> <TD><INPUT name=nombre size=25></TD></TR> <TR> <TD>Teléfono/<FONT color=#666666>Phone</FONT>:</TD> <TD><INPUT name=telefono size=25></TD></TR> <TR> <TD>FAX:</TD> <TD><INPUT name=fax size=25></TD></TR> <TR> <TD>email:</TD> <TD><INPUT name=email size=25></TD></TR></TBODY></TABLE></TD> <TD vAlign=top width="50%"> <TABLE border=0 cellPadding=1 cellSpacing=0> <TBODY> <TR> <TD colSpan=2><B>Datos Empresa / <FONT color=#666666>Business Data</FONT></B> <P></P></TD></TR> <TR> <TD>Nombre/<FONT color=#666666>Name</FONT>:</TD> <TD><INPUT name=empresanombre size=25></TD></TR> <TR> <TD>C.I.F.:</TD> <TD><INPUT name=cif size=25></TD></TR> <TR> <TD>Dirección/<FONT color=#666666>Address</FONT>:</TD> <TD><INPUT name=direccion size=25></TD></TR> <TR> <TD>Ciudad/<FONT color=#666666>Town</FONT>:</TD> <TD><INPUT name=ciudad size=25></TD></TR> <TR> <TD>Teléfono/<FONT color=#666666>Phone</FONT>:</TD> <TD><INPUT name=empresatelefono size=25></TD></TR> <TR> <TD>FAX:</TD> <TD><INPUT name=empresafax size=25></TD></TR> <TR> <TD>email:</TD> <TD><INPUT name=empresaemail size=25> </TD></TR></TBODY></TABLE></TD></TR> <TR> <TD colSpan=2> <HR> </TD></TR> <TR> <TD vAlign=top width="50%">Método Preferido para la Confirmación de la reserva<BR><FONT color=#666666>Preferred Confirmation Method</FONT> <P><INPUT CHECKED name=contactby type=radio value=FAX>FAX<BR><INPUT name=contactby type=radio value=email>email<BR><INPUT name=contactby type=radio value=Phone>Teléfono/<FONT color=#666666>Phone</FONT><BR></P></TD> <TD vAlign=top width="50%">¿Dónde desea que le sea confirmada la reserva?<BR><FONT color=#666666>Where would you like to receive the confirmation?</FONT> <P><INPUT name=contactin type=radio value=domicilio>Domicilio/<FONT color=#666666>Home</FONT><BR><INPUT name=contactin type=radio value=empresa>Empresa/<FONT color=#666666>Company</FONT> <P></P></TD></TR> <TR> <TD colSpan=2><B>Reserva de Habitaciones / <FONT color=#666666>Room Reservations</FONT></B><BR>Especifique el tipo y nª de habitaciones. Fecha de entrada y nª de noches.<BR><FONT color=#666666>Specify the type and nª of rooms. Date of entering and nª of nights. <P></FONT> <CENTER> <TABLE border=0 cellPadding=1 cellSpacing=0 width="80%"> <TBODY> <TR> <TD>Nª/<FONT color=#666666>Qty</FONT></TD> <TD></TD> <TD>Fecha/<FONT color=#666666>Date</FONT></TD> <TD>Nª de Noches/<FONT color=#666666>Nights</FONT></TD></TR> <TR> <TD><INPUT name=dobinnume size=2></TD> <TD>Simple Uso Individual/<FONT color=#666666>Simple Single Use</FONT></TD> <TD><INPUT name=dobinfech size=10></TD> <TD><INPUT name=dobinnoch size=2></TD></TR> <TR> <TD><INPUT name=doblenume size=2></TD> <TD>Doble/<FONT color=#666666>Double</FONT></TD> <TD><INPUT name=doblefech size=10></TD> <TD><INPUT name=doblenoch size=2></TD></TR> <TR> <TD><INPUT name=convenume size=2></TD> <TD>Habitación (Ejecutiva)/<FONT color=#666666>Room (Executive)</FONT></TD> <TD><INPUT name=convefech size=10></TD> <TD><INPUT name=convenoch size=2></TD></TR> <TR> <TD><INPUT name=jrsuinume size=2></TD> <TD> Suite (Diplomática)/<FONT color=#666666> Suite (Diplomatic)</FONT></TD> <TD><INPUT name=jrsuifech size=10></TD> <TD><INPUT name=jrsuinoch size=2></TD></TR> <TR> <TD><INPUT name=suitenume size=2></TD> <TD>Suite (Presidencial)/<FONT color=#666666>Suite (Presidential)</FONT></TD> <TD><INPUT name=suitefech size=10></TD> <TD><INPUT name=suitenoch size=2></TD></TR></TBODY></TABLE></CENTER></TD></TR> <TR> <TD colSpan=2><FONT face=arial><B>Comentarios / <FONT color=#666666>Comments</FONT></B></FONT><BR> <CENTER><TEXTAREA cols=60 name=t_comentarios rows=5 wrap=physical></TEXTAREA></CENTER><BR></TD></TR> <TR> <TD colSpan=2> <HR> Por favor, seleccione <EM>"Enviar / Send"</EM> para enviarnos esta información, o <EM>"Borrar / Clear"</EM> para empezar de nuevo:<BR><FONT color=#666666>Please select <EM>"Enviar / Send"</EM> to send us this information, or <EM>"Borrar / Clear"</EM> to start over:</FONT><BR></TD></TR> <TR> <TD align=left> <input type="Submit" name="enviar" value="Enviar / Send" > </TD> <TD align=right><INPUT type=reset value="Borrar / Clear"><BR></TD></TR> <TR> <TD colSpan=2> <HR> </FORM> <?php } ?> </BODY></HTML> HELP MI FASHION EMERGENCY!!! GRACIAS A TODOS!!

« previous php.general.es (#20880) next »