• Resolved hkcharlie

    (@hkcharlie)


    I’m getting an error on every page except my home (blog) page.
    This is:
    Warning: Cannot modify header information – headers already sent by (output started at /home/backinfi/public_html/wp-content/themes/backin5mins_2010/header.php:2) in /home/backinfi/public_html/wp-includes/pluggable.php on line 868

    I have looked for spaces in the header.php
    I have no idea what it means by header.php:2

    I looked for spaces in the wp-config.php, there aren’t any.

    If I log in as admin, I do not get the error and every page views perfectly.

    Can anyone please help?

Viewing 12 replies - 1 through 12 (of 12 total)
  • Shane G.

    (@shane-g-1)

    Hi,

    It is usually due to spaces, new lines, or other garbage at opening/closing PHP file <?php tag or after a closing ?> tag in wp-config.php. It can be other file too so need to check error message as it may list file name where the error occurred.

    You can either upload error file from the backup or edit erroneous file. To edit the file one need to check below mentioned points:

    1. Download the file mentioned in the error message.
    2. Open that file in a plain text editor
    3. Check that the very first characters are <?php
    4. Check that the very last characters are ?>
    5. Place the cursor between the ? and >
    6. Now press the DELETE key on your computer and keep that key pressed for at least 15 seconds.
    7. Now type > and
    8. Save without pressing any other key at all.

    That’s it!

    Thanks,

    Shane G.

    Thread Starter hkcharlie

    (@hkcharlie)

    Hi Shane,
    thanks for the reply, your explanation of this “fix” is very clear and precise, however it does not work for me in this instance.
    Any other ideas please?

    Shane G.

    (@shane-g-1)

    Hi,

    Please try to upgrade your wordpress to the latest version 2.9.2. If it is already upgraded then download fresh copy of the wordpress and reinstall wp-admin and wp-includes folders with all files and folders.

    Thanks,

    Shane G.

    sethmarie

    (@sethmarie)

    Im having the same problem except I cant even log into my account. I can get to my log in page, but not to the admin portion…
    Warning: Cannot modify header information – headers already sent by (output started at /home/thrashw1/public_html/public/wp-content/plugins/wp-google-buzz/wp-google-buzz.php:1631) in /home/thrashw1/public_html/public/wp-login.php on line 314

    Thread Starter hkcharlie

    (@hkcharlie)

    Hi Shane, I was already on version 2.9.2, but I updated the files with new ones downloaded from the wordpress website as you suggested.

    Still the same error!

    I saw another solution that included (as well as what you have said) saying:
    “Also check the encoding of the file. If the file is encoded as UTF-8 with BOM, the BOM is seen as a character which starts the output.”

    How do you check the encoding of the file?
    And how do you change it if you need to?

    Thread Starter hkcharlie

    (@hkcharlie)

    Anyone? I have looked and I can’t see how to do it. Having said that, I’m guessing if I replaced all the files with a new wordpress download, this solution shouldn’t be relevant anyway.

    Shane G.

    (@shane-g-1)

    Hi,

    It is the issue in wp-google-buzz plugin. Please download a fresh copy of it and upload it again.

    Thanks,

    Shane G.

    edda197

    (@edda197)

    sethmarie – i have the same problem with this msg when i got on my login page (i can’t even log in)

    Warning: Cannot modify header information – headers already sent by (output started at /home1/ponidive/public_html/eddangel/wp-content/themes/cooking-blog-theme/functions.php:11) in /home1/ponidive/public_html/eddangel/wp-includes/pluggable.php on line 865

    did u find a solution?

    thanks

    edda

    henkholland

    (@henkholland)

    Hi edda,

    Check the file functions.php in your themes/cooking-blog-theme/ folder.
    It should start on the first line with <?php and end a the very last line with ?> and NO empty lines after that.

    Thread Starter hkcharlie

    (@hkcharlie)

    Shane – I don’t have that plugin installed !

    alism

    (@alism)

    hkcharlie,

    “output started at /home/backinfi/public_html/wp-content/themes/backin5mins_2010/header.php:2”

    Have another look at the header.php file. The “:2” is referring to line 2 of that file. Which suggests you’ve perhaps got a space or something on line 1.

    As henkholland says, make sure the very first line starts with a <?php and nothing before that. Put your cursor just before the first < and hit backspace a few times just to make sure, then save it again. Otherwise, restore the original header.php that came with the theme.

    Thread Starter hkcharlie

    (@hkcharlie)

    After a lengthy investigation of check and check again, this turned out to be a conflict with a user permissions plugin
    https://urbangiraffe.com/plugins/user-permissions/

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Headers already sent error’ is closed to new replies.