Skip to main content
added 67 characters in body
Source Link
ServerBloke
  • 412
  • 1
  • 11
  • 20

I can't get a custom error document to work for 400 Bad Request. It's a CentOS LAMP server.

ErrorDocument 400 /badrdoc.html 

I've tried using the above in:

  1. Apache http.conf
  2. Apache httpd-vhosts.conf (in each vhost)
  3. .htaccess in the root htdocs of the site

None of them are working. Apache is serving its default 400 Bad Request page.

Can anyone shed any light on this?

Edit: forgot to mention, I have restarted Apache after changes.

I can't get a custom error document to work for 400 Bad Request. It's a CentOS LAMP server.

ErrorDocument 400 /badrdoc.html 

I've tried using the above in:

  1. Apache http.conf
  2. Apache httpd-vhosts.conf (in each vhost)
  3. .htaccess in the root htdocs of the site

None of them are working. Apache is serving its default 400 Bad Request page.

Can anyone shed any light on this?

I can't get a custom error document to work for 400 Bad Request. It's a CentOS LAMP server.

ErrorDocument 400 /badrdoc.html 

I've tried using the above in:

  1. Apache http.conf
  2. Apache httpd-vhosts.conf (in each vhost)
  3. .htaccess in the root htdocs of the site

None of them are working. Apache is serving its default 400 Bad Request page.

Can anyone shed any light on this?

Edit: forgot to mention, I have restarted Apache after changes.

Source Link
ServerBloke
  • 412
  • 1
  • 11
  • 20

Apache ErrorDocument directive not working

I can't get a custom error document to work for 400 Bad Request. It's a CentOS LAMP server.

ErrorDocument 400 /badrdoc.html 

I've tried using the above in:

  1. Apache http.conf
  2. Apache httpd-vhosts.conf (in each vhost)
  3. .htaccess in the root htdocs of the site

None of them are working. Apache is serving its default 400 Bad Request page.

Can anyone shed any light on this?