Ver Mensaje Individual
  #1 (permalink)  
Antiguo 29/04/2004, 15:59
varuk
 
Fecha de Ingreso: abril-2004
Mensajes: 107
Antigüedad: 20 años
Puntos: 0
Página con contraseña, problemas

Hola. He intentado hacer una página que para verla haya que meter un usuario y contraseña. ¿Dónde está el fallo? Lo digo porque entro a la página y se ve el texto que no tendría que verse sin autentificarse. Este es el script:

Código PHP:
<FORM ACTION="password.php" METHOD="post">
  <div align="center">Usuario 
    <input name="usuario" type="text" id="usuario">
    Password 
    <input name="password" type="password" id="password" SIZE="20" MAXLENGTH="30">
    <input type="submit" name="Submit" value="Enviar">
    <input type="reset" name="reset" value="Borrar">
  </div>
</FORM></p>
<?php
if ($usuario=="user" && $password=="pass") { ?> 
<html>
<head>
<title>Documento sin t&iacute;tulo</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body>
bienvenido a la web : ) 
</body>
</html>
<?php ?>
Gracias gente