[Php-it] [OT !/2] riscrivere gli errori di apache webserver
RedFoxy
redfoxy at redfoxy.it
Mon Oct 1 15:40:30 CEST 2007
Ciao a tutti!
Ho un problema che mi sta' facendo mangiare il fegato...
Per ora mi capita che gli utenti vadano in BAD REQUEST quando si
collegano al mio sito per un cookies con il nome troppo lungo, ora ho
rinominato il cookie ma quelli che ancora non lo hanno cancellato
ricevono la pagina di bad request...
Fin qui ok... Per ovviare ho preso e mi son creato le mie pagine di
errore, cambiando gli include top e bottom rispetto quelli standard di
apache2, mettendo nel bottom dei link per poter risolvere il problema
(una spiegazione di come cancellare i cookies per i vari browser), ora
se provate a fare un 404 andando ad un url palesemente errato (tipo
http://www.softairmania.it/index.php_ ) vedrete le pagine riscritte, ma
quando si genera l'errore di BAD REQUEST gli utenti vedono sempre la
pagina standard di APACHE... La cosa mi sta' facendo uscire pazzo!
Questa e' la conf che ho messo in apache per questo vhost:
ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var
ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
ErrorDocument 410 /error/HTTP_GONE.html.var
ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var
ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var
Praticamente ho copiato quelli di apache2 e poi ho cambiato solo i file
include top.html e bottom.html ma niente gli utenti vedono sempre il
classico errore 400 standard...
Idee?
NB: penso sia il classico errore di apache perche' e' di solo testo ed
in coda c'e' il resoconto del server con nome, versione etc...
--
RedFoxy
A fox around web
Power at fox for a yiffing world!
Un forum per tutte le esigenze: http://www.forum.redfoxy.it
More information about the Php-it
mailing list