The MU forums have moved to WordPress.org

headers already sent error in pluggable.php (16 posts)

  1. mshao
    Member
    Posted 17 years ago #

    I just upgraded my site to the latest nightly build. After a user clicked on the activation link inside the notify email, he got this error:

    header already sent .....
    /home/mshao/public_html/wp-includes/pluggable.php on line 311

    I compared the new and old code at the line numebred.

    New:
    function wp_clearcookie() {
    global $base;
    setcookie(USER_COOKIE, ' ', time() - 31536000, $base, COOKIE_DOMAIN);
    setcookie(PASS_COOKIE, ' ', time() - 31536000, $base, COOKIE_DOMAIN);
    }

    Old:
    function wp_clearcookie() {
    setcookie(USER_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN);
    setcookie(PASS_COOKIE, ' ', time() - 31536000, COOKIEPATH, COOKIE_DOMAIN);
    setcookie(USER_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN);
    setcookie(PASS_COOKIE, ' ', time() - 31536000, SITECOOKIEPATH, COOKIE_DOMAIN);
    }

    With the error, the activation was successful however. Any ideas?

    Thanks

  2. drmike
    Member
    Posted 17 years ago #

    There should be more to that error. Should talk about two files.

    Need the complete and total error please.

  3. drmike
    Member
    Posted 17 years ago #

    Just to follow up, the reason why i was asking for the complete error message is because this is discussed over in the Codex and it's usually the first file mentioned (I think I'm reading that right) that's causing the issue.

  4. thatposhgirl
    Member
    Posted 17 years ago #

    I installed on my testsite. http://yourowndiary.com

    The first file is themes/home/header.php

    eta.

    I replaced pluggable.php with one from the 8/24 build that has been patched and the header.php file with the one from the 8/24 build and the error is still there so it is probably not in either of those files?

  5. mshao
    Member
    Posted 17 years ago #

    drmike,
    You're very right. The other file mentioned in the error message is modified header.php in the theme used by my home page. It complained about line #5. Below is the file content. Any advise?

    [delete code since it mucks up my browser - drmike]

  6. drmike
    Member
    Posted 17 years ago #

    Posh, actually I can't even get your site to come up. I'm seeing a 500 error when I try to load http://yourowndiary.com/

    Is there anything in your logs?

    I would check your file permissions to start with. Files should be set to 644, directories to 755, and your blogs.dir subdirectory would be set to 777.

    I'll be here for a couple more hours. If you're stuck, please drop me an email at theapparatus ( at ) gmail ( dot ) com with your host's backend username and password and I can take a look for you.

    mshao, please post a copy of your header.php, not your output. It owuld be easier if you posted it to a *.txt or *.phps file somewhere on your site instead of here in the forums as it gets chewed up.

  7. mshao
    Member
    Posted 17 years ago #

    drmike,
    I am sending you an email.

    Thanks

  8. thatposhgirl
    Member
    Posted 17 years ago #

    Yeah things just went pear-shaped on my site. I'm working on it.

  9. drmike
    Member
    Posted 17 years ago #

    Posh, I see you site now. The yourowndiary is forwarding to the signup page though for screenwriters.la. I don't know if that is the way you want it though.

  10. thatposhgirl
    Member
    Posted 17 years ago #

    I had aliased yourowndiary.com to my screenwriters.la hosting account and I think there was some sort of conflicgt with the .htaccess files and everything started throwing errors. So, I deleted the aliased domain from screenwriters.la and transfered all the yourowndiary stuff to a different account but the nameservers haven't resolved yet so it is still forwarding to screenwriters.la.

  11. thatposhgirl
    Member
    Posted 17 years ago #

    Ok yourowndiary.com should be working again. You can see the errors when you try to create a blog. I think the problem is in wp-includes/general-template.php

  12. drmike
    Member
    Posted 17 years ago #

    Posh, worked fine for me. No errors using Firefox 1.5.0.7. :)

    mshao, I sent you back a response. I can't dupe the error.

  13. thatposhgirl
    Member
    Posted 17 years ago #

    Oops, Dr. Mike you made a blog at screenwriters.la. http://yourowndiary.com isn't coming up on its own site on your end yet?

    It makes the blog, btw. It just gives a lot of warnings when it does it which is bot good if you are public.

  14. drmike
    Member
    Posted 17 years ago #

    Still doing the redirect. I'll take a look at it tomorrow if I get a chance.

  15. Aashie
    Member
    Posted 17 years ago #

    I am having exactly the same problem. :(

    Did you find a solution?

    I looked at all the solutions for the error that's occurring but it doesn't seem to apply to header.php which is apparantly where the error is coming from (according to the solutions given). If I take that whole line out of the file, it just happens at the next instance of a php call so I am thinking that the problem is in another file.

    Error below:

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 329

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 330

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 331

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 332

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 317

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 318

    Warning: Cannot modify header information - headers already sent by (output started at /var/www.dev/wp-content/themes/default/header.php:5) in /var/www.dev/wp-includes/pluggable.php on line 321

  16. isnpms
    Member
    Posted 15 years ago #

    I had this problem when i've upgraded to vrsion 2.5. That was because i was using a old PT (portuguese) version then i had upgraded to a 2.5 English version. This gave me the same error messages you have. Everything was resolved when i changed teh 2.5 EN to 2.5 PT.

About this Topic