Re: Me trae loco esto Como pasar variables?

From: Date: Mon, 10 Mar 2003 15:25:32 +0000
Subject: Re: Me trae loco esto Como pasar variables?
References: 1 2 3  Groups: php.general.es 
Request: Send a blank email to general-es+get-33500@lists.php.net to get a copy of this message
Veamos ... el SQL es : >$sel="INSERT INTO $dbTable (FirstN, LastN, AccountNum, PhoneNum, Comments, >ID) VALUES (\$FirstN\", \"$LastN\", \"$AccountNum\", >\"$PhoneNum\", >\"$Comments\", \"$\")"; ¿Donde estableces los valores de $LastN, $AccountNum, ... ? ... esto del copy-paste XD _.-. _.-. _.-. _.-. EN RESPUESTA A _.-. _.-. _.-. _.-. _.-. Sistemas comentaba el [10/3/03-8:16] sobre " Re: [PHP-ES] Me trae loco esto Como pasar variables?": >Estimado Amigos Listeros: > >Este equeño programa me trae loco desde hace rato,,,, >Oigan tengo un script en php donde capturo los datos de las variables, y >los >paso a otro script por medio de $_POST. Pero no me escribe nada en la >Tabla............ >que creen que sera? > >Aqui es mi pantalla de captura de datos: ><html> > ><head> > ><LINK REL=stylesheet HREF="../Stylesheets/Stylesheet.php" >TYPE="text/css"> > ><meta http-equiv="content-type" >content="text/html;charset=ISO-8859-1"> > ><meta name="generator" content="Adobe GoLive 6"> > ><title>Alta de Nueva Cuenta</title> > ><style type=text/css> > >table,td,tr,th > >{ > >border-width: 0; > >} > ></style> > ></head> > ><body bgcolor="#ffffff"> > ><h3 align='center'> Alta de Cuentas</h3> > ><form action="addcta.php" method="Post" name="AddCustomer"> > ><table width="581" border="0" cellspacing="2" >cellpadding="0" height="116"> > ><tr> > ><td width="131">Numero de Cuenta:</td> > ><td><input type="text" name="cuenta" >size="2"></td> > ></tr> > ><tr> > ><td width="131">Nombre:</td> > ><td><input type="text" name="nombre" >size="40"></td> > ></tr> > ><tr> > ><td width="131">Fecha de Inicio:</td> > ><td><input type="text" name="fechainicio" size="12" >maxlength=12></td> > ></tr> > ><tr> > ><td valign=top width="131"> > >Comentarios: <td><textarea name="Comentarios" rows="6" >cols="48"></textarea> > ></table><table><tr><td width=400 align=center> > ><input type="submit" name="Agregar" >value="Agregar">&nbsp;&nbsp;<input >type="reset" name="Cancelar" value="Cancelar"> > ></table> </form> > ></body> > ></html> > > > >Aqui es donde grabo mi registro.. > ><?php > > > >//Adds a Customer to the database and checks for errors. > > > >$cuenta=$_POST['cuenta']; > > > >$nombre=$_POST['nombre']; > > > >$fechainicio=$_POST['fechainicio']; > > > >$Comentarios=$_POST['Comentarios']; > > > >$AddCustomer=$_POST['AddCustomer']; > > > >$msg="Cuenta: $cuenta\nNombre: $nombre\nFechaInicio: >$fechainicio\nComentarios: $Comentarios\nAddCustomer: $AddCustomer\n"; > >include ("../settings.php"); > > > >$dbHost="$server"; > > > >$dbName="$database"; > > > >$dbUser="$username"; > > > >$dbPass="$password"; > > > >$dbTable="customers"; > > > >$sel="INSERT INTO $dbTable (FirstN, LastN, AccountNum, PhoneNum, Comments, >ID) VALUES (\$FirstN\", \"$LastN\", \"$AccountNum\", >\"$PhoneNum\", >\"$Comments\", \"$\")"; > > > >$conn = @mysql_connect($dbHost, $dbUser, $dbPass); > > > >$dbDB = @mysql_select_db($dbName, $conn); > > > >$result = @mysql_query($sel, $conn); > > > >?> > > > ><br> > > > ><? > > > >include ("newcta.php"); > > > >?> > > > >Todo lo hace bien, pero al registrar el dato en la tabla no me pasa ningun >contenido. > > > >Saludos y espero su ayuda. > > > > > > >--------------------------------------------------------------------- >Archivo On-line: http://www.phpes.com/ > via news: news://news.phpes.com/ >Manual PHP en español: http://www.php.net/manual/es/ >Para dar de baja la suscripción, mande un mensaje a: > lista-unsubscribe@phpes.com Dr Zippie (zippie(a)dr-zippie.net) www.dr-zippie.net ** en construcción ** "El ordenador es la evolucion logica del hombre: Inteligencia sin moral": John Osborne. "A nullo videbatur, ipse autem omnia videbat"

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