Tema: problema
Ver Mensaje Individual
  #7 (permalink)  
Antiguo 15/10/2005, 19:18
blackrocha
 
Fecha de Ingreso: noviembre-2004
Mensajes: 181
Antigüedad: 19 años, 6 meses
Puntos: 1
mira en el primer codigo me tira el mismo error aunque alla cambiado en el php.ini la bariable que me dijiste tre marcare donde esta el php_self

<?php
session_start();
echo "<html>\n";
echo "<head>\n";
echo "<title>Inicio de sesion</title>\n";
echo "</head>\n";

echo "<body bgcolor='#003399' text='#00FF99'>\n";

if(isset($btningresar))
{
$enlace = mysql_connect("localhost", "root", "") or die("No pudo conectarse : " . mysql_error());
mysql_select_db("hospital") or die("No pudo seleccionarse la BD.");

$consulta="SELECT usuario.login,usuario.pas FROM usuario where LOGIN='$txtlogin' and PAS='$txtpassword'";
$res=mysql_query($consulta) or die("La consulta fall&oacute;: " . mysql_error());
mysql_close();
$num=mysql_numrows($res);

if ($num)
{
echo "<center>DATOS INGRESADOS CORRECTAMENTE</center><br>";
session_register('LOGIN');
$LOGIN=$txtlogin;
header("Location:menu.php");
}
else
{
echo "<center><h3><b>INGRESE SUS DATOS CORRECTAMENTE<b><h3></center>";
echo "<a href='$PHP_SELF'><center>ATRAS</center></a>";
}

}

else
{
echo "<center><h2><b>Mi Inicio2</b></h2></center><br><br>\n";

echo "<form action='$PHP_SELF' method='post'>\n";
echo "<center>\n";
echo "<table border='1' width='100' height='74'>\n";
echo " <tr> \n";
echo " <td width='50%' height='19'><strong><font face='Verdana'>Login</font></strong></td>\n";
echo " <td width='50%' height='19'><input name='txtlogin' type='text' size='15' maxlength='10'></td>\n";
echo " </tr>\n";

echo " <tr> \n";
echo " <td width='50%' height='18'><strong><font face='Verdana'>Password</font></strong></td>\n";
echo " <td width='50%' height='18'><input name='txtpassword' type='password' size='15' maxlength='10'></td>\n";
echo " </tr>\n";

echo "<tr> \n";
echo " <td><center><a href='inicio2.php'><img src='../general/imagen/mano.gif' border='o'></a></td></center>\n";
echo " <td><input type='submit' value='Ingresar' name='btningresar'></td>\n";
echo "</tr>\n";

echo "</table>\n";
echo "</center>\n";

echo "</form>\n";
echo "</body>\n";
echo "</html>\n";
}
?>
yo no se porq sera pero como dije arriba coloco otra pagina y me marca lo mismo como q no estan definidas las bariables y no se por dice eso si las paginas estan buenas
seria mucho si me pasaras un codigo como para verificar secion actualisado porfa .... gracias