Ver Mensaje Individual
  #1 (permalink)  
Antiguo 21/06/2013, 04:36
AitorLopez
 
Fecha de Ingreso: mayo-2009
Mensajes: 742
Antigüedad: 15 años
Puntos: 6
Problema con cabeceras

Hola. Mirad, tengo este codigo en el inicio del index
Código PHP:
Ver original
  1. header("Content-Type: text/html;charset=utf-8");
  2. /*FUNCIONES PARA QUE TIRE DE LA CACHÉ, O NO:*/
  3. function si_cache()
  4. {
  5.     header('expires: Sat, 10 May 2014 13:22:48 GMT');
  6.     return;
  7. }
  8.  
  9. function no_cache()
  10. {
  11.     if(headers_sent()) return FALSE;
  12.  
  13.     header('pragma: public'); # HTTP/1.0
  14.     header('expires: Sat, 11 May 2013 13:22:48 GMT');
  15.     @header('last-modified: ' . gmdate('D, d M Y H:i:s') . ' gmt'); # !
  16.     @header('cache-control: no-store, no-cache, must-revalidate'); # HTTP/1.1
  17.     header('cache-control: private, post-check=0, pre-check=0, max-age=0', FALSE); # HTTP/1.1
  18.     header('pragma: no-cache'); # HTTP/1.0
  19.     header('expires: 0');
  20.     return;
  21. }
  22.  
  23. si_cache();

Se os ocurre alguna idea de que, a pesar de tener este codigo en el inicio del index, la informacion que me devuelve de las cabeceras que envio es:

Date: Fri, 21 Jun 2013 10:39:41 GMT

Server: Apache

X-Powered-By: PHP/5.4.16

Expires: Thu, 19 Nov 1981 08:52:00 GMT

Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0

Pragma: no-cache

Keep-Alive: timeout=2, max=200

Connection: Keep-Alive

Transfer-Encoding: chunked

Content-Type: text/html;charset=utf-8


200 OK