tengo un problema con un php.
Para la creación de zonas de acceso restringido por medio de variables en el servidor.
A ver si alguien me puede ayudar. Estoy haciendo una prueba pero me aparece el siquiente error:
Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at C:\AppServ\www\php\archivo\sesiones1.php:9) in C:\AppServ\www\php\archivo\sesiones1.php on line 10
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at C:\AppServ\www\php\archivo\sesiones1.php:9) in C:\AppServ\www\php\archivo\sesiones1.php on line 10
0
el php es:
<?php
session_start();
if (!isset($_SESSION['contador'])) {
$_SESSION['contador'] = 0;
}else{
$_SESSION['contador']++;
}
echo $_SESSION['contador'];
?>