Ver Mensaje Individual
  #8 (permalink)  
Antiguo 15/01/2009, 14:21
tirengarfio
 
Fecha de Ingreso: septiembre-2008
Mensajes: 146
Antigüedad: 16 años, 6 meses
Puntos: 1
Respuesta: Pasar una variable php en una pagina con un formulario

Gracias de nuevo,

de todos modos sigo sin poder imprimir la variable PHP en la pagina de destino (resultado_busqueda.php).

Aqui estan los codigos:

Código PHP:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head><title></title>

<style type="text/css" media=all>

</style>
</head>

<body>


<form method="POST" action="http://localhost/red_social/resultado_busqueda.php">

<?php

$var
="Hola";

?>

<input type="text" name="nombre"><br>
<input type="text" name="apellidos"><br>
<input type="text" name="email"><br>
<input type="text" name="telefono"><br>
<input type="text" name="domicilio"><br>
<input type="text" name="fechanacimiento"><br>

<input type="submit" name="Buscar"><br>

<input name="flag" type="hidden" id="flag" value="vari=<?php echo $var ?>">



</form>


</body>

</html>
Código PHP:
<html>
<head><title></title>

<style type="text/css" media=all>

</style>
</head>

<body>

<?php

echo $_GET["vari"];

?>

</body>

</html>