| | |||||
| ||||||||
| Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics. |
![]() |
| | LinkBack | Thread Tools |
| | THREAD STARTER #1 (permalink) |
| NamePros Member Join Date: Jul 2003
Posts: 118
![]() | Whats this error about I have got this error and I dont have a glue what its about could any one shade any light on this. ------------ Warning: Cannot add header information - headers already sent by (output started at /usr/local/psa/home/vhosts/paulicon.co.uk/httpdocs/functions.php:66) in /usr/local/psa/home/vhosts/paulicon.co.uk/httpdocs/delete.php on line 22 ------------- Thanx in advance.
__________________ Paulicon Web design - Your one stop shop |
| |
| | #3 (permalink) |
| Senior Member Join Date: Aug 2002
Posts: 1,255
![]() ![]() | It basically means that your script has already sent some Headers to the browser meaning something like white space, or html or some other headers, and then attempting to do it again, but it can't because the headers have already been sent or something like that. ![]() ????: NamePros.com http://www.namepros.com/programming/15096-whats-this-error-about.html Some possible things that could cause it is white space before your opening delimiter and all the possiblilites with what was mentioned above ![]() Example, these wouldn't work: PHP Code: PHP Code: |
| |
| | #5 (permalink) | ||||
| NamePros Regular Join Date: Jun 2003 Location: California
Posts: 245
![]() |
__________________ --Alpha | ||||
| |
| | #6 (permalink) | ||||
| Senior Member Join Date: May 2003
Posts: 2,187
![]() ![]() ![]() |
| ||||
| |
| | THREAD STARTER #7 (permalink) |
| NamePros Member Join Date: Jul 2003
Posts: 118
![]() | Thanx i have sloved the problem. It was to do with where I was calling the php file fiunctions.php into the script e.g requre("functions.php"). It dident have anything to do with header being called twice cause it wasent. Strange!!
__________________ Paulicon Web design - Your one stop shop |
| |
| | #8 (permalink) | ||||
| Senior Member Join Date: Aug 2002
Posts: 1,255
![]() ![]() |
What did you do to fix it? Maybe move the require up before any other code or white space or something else? | ||||
| |
| | THREAD STARTER #9 (permalink) |
| NamePros Member Join Date: Jul 2003
Posts: 118
![]() | I moved the required field into an if else statement, ------------ if{ header("Location...... } else{ required("functions.php"); } ------------ This is a scaled down version of the code. It was strange because I run php4 on my test server and it worked fine, but when I uploaded to my online server which runs php3 it through up the error. Ah well the joys of programming
__________________ Paulicon Web design - Your one stop shop |
| |
| | #10 (permalink) | ||||
| Senior Member Join Date: Aug 2002
Posts: 1,255
![]() ![]() |
And yea, I have had that same error occur many times with php scripts. :beer: :webdev: | ||||
| |