Hola estoy intentado redirigir a un archivo cuando un usuario no este autentificado y no se porque me da error, a continuación pego el código:
<?
include ("conexion.php");
include ("login.php");
if($loginCorrecto)
{
echo "";
}
else
{
header("Location:error.php");
exit;
}
?>
<html>
<head>
<title>xxxxxxxx</title>
</head>
<body>
xxxxxxxxxxxxx
</body>
</html>
El error que me devuelve es el siguiente:
Warning: Cannot add header information - headers already sent by (output started at c:\apache\htdocs\autentificacion\login.php:32) in c:\apache\htdocs\autentificacion\asociados.php on line 10
Gracias desde ya, un saludo.