I have the following tag for when a user is successfully logged in:
header('Location: /members');
It always used to work. Now, however, when I try to load the page, Chrome gives me this error:
HTTP Error 500 (Internal Server Error): An unexpected condition was encountered while the server was attempting to fulfill the request.
On Firefox, I just get a blank page. When I comment the header statement out, it works, but without the redirect (obviously).
I have tried it with output buffering on and off, with the same effect. Any ideas?
Edit: I have a PHP header statement at the beginning of the code that redirects users to the member page if they are already logged in. Could this be affecting it? I'm not getting any headers already sent errors...
headercall?exit()just afterheader()and writeob_start()at the top of the page