$PHP_SELF sobreA Form Action
| From: | big11ko | Date: | Tue, 14 Jan 2003 09:01:07 +0000 |
| Subject: | $PHP_SELF sobreA Form Action | ||
| Groups: | php.general.es | ||
| Request: | Send a blank email to general-es+get-31117@lists.php.net to get a copy of this message | ||
olas ...
+Salud...2+
Tengo este problema y.... necesito alguna referencia para solucionaresto
Aqui parte del script e informacion adicional :
- register_globals=off
Los mensajes de error son de variable indefinida
Notice: Undefined variable: action in
Notice: Undefined variable: action in
Claro, que no por esto deja de funcionar el script. Es que no me gusta pe...
Se agradece la informacion y/o sugerencias
joya
[...]
$PHP_SELF=$HTTP_SERVER_VARS["PHP_SELF"];
[...]
<FORM action="<?$PHP_SELF;?>?action=login" method="post">
# He probado con : <FORM action="<?$_SERVER["PHP_SELF"];?>?action=login" method="post"> pero se agrava
# la situacion.
<P>Username: <INPUT type="text" name="username">
<P>Password: <INPUT type="password" name="password">
<P><INPUT type="submit" value="Log-in">
</FORM>
<?endif;
[...]
<?exit;
}?>
</body>
</html>
[...]
<!--signup.phtml-->
<html>
<head>
<title>Accion de Login</title></head> <body> <? if($action == "login") {
# Aqui probe con : if ($HTTP_GET_VARS['action']=="login") {
# y obtengo indefinido indice
# Hacer bla,blailled out.
}
[...]