Ver Mensaje Individual
  #1 (permalink)  
Antiguo 06/01/2004, 21:02
tiniebla
 
Fecha de Ingreso: noviembre-2003
Mensajes: 92
Antigüedad: 20 años, 5 meses
Puntos: 2
Ayudita con un error

Hola, estoy haciendo unas paginas que requieran identificacion, pero al acceder a alguna de ellas me da el siguiente error


Parse error: parse error, unexpected T_STRING in c:\appserv\www\identificacion\seguridad.php on line 11


----
Este es el código


<?
/* Autenticación
*/
$muerte = 'Area Restringida!!!! ;

if(!isset($_SERVER['PHP_AUTH_USER'])) {
header('WWW-Authenticate: Basic realm="Nombre del Site"');
header('HTTP/1.0 401 Unauthorized');
echo $muerte;
exit;
} else {
// valido mi clave en el servidor ...
if (@$db_link = mysql_connect("localhost", "tiniebla", "tiniebla")) {
@mysql_select_db("login");
}

$sql = "select * from user
where ((user = $_SERVER['PHP_AUTH_USER')
and (pass = $_SERVER['PHP_AUTH_PW')) ";

$qpass= mysql_query($sql, $db_link);
if(mysql_num_rows($qpass)<>1) {
echo $muerte;
exit;
}

}
?>



GRACIASS