Ver Mensaje Individual
  #3 (permalink)  
Antiguo 09/12/2014, 08:43
ut261c
 
Fecha de Ingreso: noviembre-2014
Ubicación: peru-lima
Mensajes: 32
Antigüedad: 9 años, 5 meses
Puntos: 2
Respuesta: validar campo de texto, lado servidor

solucionado --- gracias... se podra mostrar con metodo POST en bnvnd.php cambiando el codigo header("Location:bnvnd.php?comprobar=".$comprobar) ;(solo da GET)

entrar.php

<html>
<form method=post action=v.php>
<head>
<title> prueba </title>
</head>
<body>
<input type=text name=textbox1>
<?php
if (isset($_REQUEST['msg'])) {
$name = $_REQUEST['msg'];
echo $name;
} else {
$name = "";
}
?>
<input type=submit value=ingresar>
</body>
</from>
</html>
---------------------------------------------------------------------------------
v.php

<?php
$comprobar = $_POST['textbox1'];

if ($comprobar == ""){
$msg = "llenar campos";
header("Location:entrar.php?msg=".$msg);
}
else{

header("Location:bnvnd.php?comprobar=".$comprobar) ;
}
?>

--------------------------------------------------------------------------------------
bnvnd.php

<?php
$r = $_GET['comprobar'];
echo $r;
?>