RE: [PHP] Warning?
| From: | Chad Day | Date: | Mon, 30 Dec 2002 16:36:01 +0000 |
| Subject: | RE: [PHP] Warning? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-129684@lists.php.net to get a copy of this message | ||
You can't have any text output to the browser before a redirect. Make sure
you have nothing abouve line 58 echoing out text (specifically whatever is
in line 2, judging by your error) .. I believe I've had the problem when
I've included a file where the 1st line was blank, so you may want to check
that as well..
Chad
-----Original Message-----
From: Doug Coning [mailto:lists@coning.com]
Sent: Monday, December 30, 2002 12:25 PM
To: php general
Subject: [PHP] Warning?
Hi everyone,
I'm using Dreamweaver to create an insert page and after the record is
inserted I receive this error:
Warning: Cannot add header information - headers already sent by (output
started at
/home/virtual/site8/fst/var/www/html/admin_gs/products_insert.php:2) in
/home/virtual/site8/fst/var/www/html/admin_gs/products_insert.php on line 62
Line 58 - 62 is as follows:
if (isset($HTTP_SERVER_VARS['QUERY_STRING'])) {
$insertGoTo .= (strpos($insertGoTo, '?')) ? "&" : "?";
$insertGoTo .= $HTTP_SERVER_VARS['QUERY_STRING'];
}
header(sprintf("Location: %s", $insertGoTo));
This same code works in my update page without an error.
If you can help, thank you!!!!
Doug
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php