• Hi,

    After upgrading to 2.5.7 (WP version 3.2.1) I get the following error:

    Warning: Cannot modify header information – headers already sent by (output started at /XXX/wp-content/plugins/wp-htaccess-control/wp-htaccess-control.php:1) in /XXX.pl/wp-content/plugins/wp-super-cache/wp-cache-phase2.php on line 77

    I did upgrade one more site on the same hosting machine and it works fine (the config for wp-htaccess-control and wp-supercache is EXACTLY the same on both sites). I tried refreshing the cache for wp-supercache and resaving the options in your plugin. Didn’t work. It did work fine prior the latest update.

    Please look into this.

    Cheers,
    Chris Trynkiewicz

Viewing 11 replies - 1 through 11 (of 11 total)
  • Have you tried to go to line #77 in the file wp-content/plugins/wp-super-cache/wp-cache-phase2.php t understand where the error comes from ?

    Yup.

    if($wp_cache_gzip_encoding)
    header(‘Vary: Accept-Encoding, Cookie’);
    else
    header(‘Vary: Cookie’);
    ob_start( ‘wp_cache_ob_callback’ );

    The bolded line is #77. It is the same on both sites. It must be something that changed since 2.5.5 as wp-super-cache did not update since and I did not make any other changed other than updating wp-htaccess-control.
    Thanks for the prompt reply!

    ooh, bolding in a code block doesn’t work. anyway, you get the idea 🙂

    edit: fixed the bolding 😛

    This might not be related, but upon upgrading from 2.5.5 to 2.5.7, my site layout is somewhat wrong. Specifically, it appears (in Firefox) that the page contents are shifted down about 40 pixels. This is on all external and admin pages.

    If I look at the page breakdown in Firebug, I see that a bunch of header content is within the body element. This is, of course, wrong.

    Somehow the latest version of this plugin has broken page headers.

    UPDATE: Deactivating plugin fixes problem, so it’s definitely the cause.

    Nyhm: This may be a different issue. Keep in mind that http headers (for example: “Location: http://xxx.com&#8221;) are a totally different thing than the HTML headers (for example: <meta …>).

    Yes, I do understand, but I may have read your comments too quickly and assumed my html “headers” (head element content) fit under this topic. Thank you for clarifying.

    There definitely is something wrong with the html generation when this plugin is enabled, but I can make a new topic if that doesn’t fit here.

    In addition, I used to get quite a few Premature end of script headers errors. I don’t know if that is fixed yet. Several ‘header’ issues to track down here.

    Sorry for all the trouble.
    The issue introduced on 2.5.7 was due to a wrong file encoding (which should always be UTF-8 without BOM).
    Version 2.5.8 should be ok.

    Thanks for the quick fix. Do you know if this addresses both the issues listed above (both eclare’s and mine)?

    Regarding the Premature end of script headers note above: I started getting that error before 2.5.7 (and it might not have anything to do with your plugin), but it seems to be gone upon disabling this plugin.

    Nyhm,

    I’ve never heard of that specific issue before.
    Which other plugins are you running?
    What header content is being generated?
    Could you share a live example?

    Get in touch by email and I’ll have a look at it.

    António

    @dardna – Thanks for offering to look into this, but my site is not live yet.

    I’m running a variety of other plugins (and I’m in the process of narrowing down the culprit). Header content looks normal, and I’ve never caught the problem with any kind of debug output.

    The problem is very intermittent (and hasn’t happened for a couple days now). At its worst, this happens several times per hour, just while I’m browsing the site/admin pages.

    At this point, now that you’ve resolved the prior issues, I’ll stop posting to this topic. If I find that your plugin is actually causing my symptoms, I’ll create a new topic. Thanks.

    @dardna: You are awesome! This fixed the problem. Thanks for your ultra-fast response. I’m marking this as resolved, so, Nyhm, please open another topic for your issue if you desire or keep it going here 🙂

    Best wishes to you all.

    Cheers,
    Chris Trynkiewicz

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘"Header already sent…" after upgrading to 2.5.7’ is closed to new replies.