Re: getting php to generate a 503

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



dnwo@xxxxxxxxxx wrote:
I want to write a php page that can return a 503 with some useful
information.
<?php

header("HTTP/1.0 503 Service Unavailable");
echo "Page execution failed.\n";
?>

Is what I've done so far - yet it doesn't work, the headers don't seem to be
modified and my page just returns the echoed contet and both firefox and IE
blithely ignore the fact that I set the server unavailable header :( can
anyone give me a clue as to what I've done wrong?

What did you expect to happen? The expected behaviour (unless I'm missing something) is that the browser should display the content (i.e. "Page execution failed") that you sent to it.

The 503 status is a signal to the browser, and I don't believe either Firefox or IE pass that signal on.

--
Jasper Bryant-Greene
Freelance web developer
http://jasper.bryant-greene.name/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux