This should be the easiest thing to do, but for some reason I just can't get it done.
I'm trying to get a friendly static error page to replace nasty 500 scenarios. For now I'm just trying to replicate a 500 situation on my local machine (Drupal 7 running on MAMP) by throwing in some crap characters on the top of my template.php in my theme, which does trigger a 500 situation, but for some reason the ErrorDocument directive in my .htaccess
or Apache config file has no effect.
What I'm doing is quite simply this:
ErrorDocument 500 /500.html
And I have the simplest ever static html-page in the root of my site with the name of 500.html.
Still, when I intentionally break template.php, I get the dreaded White Screen Of Death instead of my nice friendly error page.
What am I doing wrong here? I've done this a billion times in non-Drupal setups but just can't get my head around this one.
drupal_add_http_header('Status', '503 Service Unavailable');
to your 500.html?