|
Posted by Erwin Moller on 02/07/07 15:13
php newbie wrote:
> I have a simple php page in which I use
>
> header("Location: http://www.example.com/");
>
> to redirect the user to another php page. The php script works on my
> local machine but when I upload it to the web server for hosting the
> redirection does not work. Instead on one server it gives the standard
> header error
>
> Warning: Cannot modify header information - headers already sent
> by .......
>
> while on the other server, I dont see this error but it also does not
> redirect just refreshes the page when I click the Submit button.
>
> Does anybody know how can i resolve this?
> Thanks
Yes,
On one server you created output before using hedaer(), and on the other
not.
You cannot use header if you send information already.
Possibly you have an error/notice/warning/whatever on 1 server (and thus
produce output) and not on the other?
Regards,
Erwin Moller
Navigation:
[Reply to this message]
|