WordPress.org

Support

Support » How-To and Troubleshooting » Cannot modify header information – headers already sent by…

Cannot modify header information – headers already sent by…

  • this is killing me! i get this crazy error on top of my pages and can’t get rid of it! i’ve already tried deleting the whitespace in front and behind the <?Php?> tags. please help me cause this is driving me nuts! i’ve been able to install the previous versions w/ no problem. here’s my error:

    Strict Standards: Assigning the return value of new by reference is deprecated in D:\Apache2_2\htdocs\wordpress\wp-settings.php on line 232

    Strict Standards: Assigning the return value of new by reference is deprecated in D:\Apache2_2\htdocs\wordpress\wp-settings.php on line 234

    Strict Standards: Assigning the return value of new by reference is deprecated in D:\Apache2_2\htdocs\wordpress\wp-settings.php on line 235

    Strict Standards: Assigning the return value of new by reference is deprecated in D:\Apache2_2\htdocs\wordpress\wp-settings.php on line 252

    Warning: Cannot modify header information – headers already sent by (output started at D:\Apache2_2\htdocs\wordpress\wp-settings.php:232) in D:\Apache2_2\htdocs\wordpress\wp-admin\install.php on line 15

Viewing 15 replies - 1 through 15 (of 17 total)
  • Assigning the return value of new by reference is deprecated

    What version of WordPress are you running?

    What’s at D:Apache2_2htdocswordpresswp-settings.php on line 232?

    Looks like you’ve got yourself a few extra lines of code in the “wp-settings.php” file. Going by the line number, it’s probably a modified version of some V2.XX release?

    i don’t see how it could be modified too much. i downloaded it from wordpress. its v2.1.

    line 232:

    $wp_the_query =& new WP_Query();

    I have the same problem. phi-nom, did you solved this?

    Tnx.

    lol. i just managed to kill those annoying messages..

    You should go to your php.ini and remove E_STRICT from your php error_reporting. Ofcourse, if you have acces to this data on your server.

    If you don’t, call your hosting provider 🙂

    What version of PHP are you running?

    i tried removing E_STRICT. still doesn’t help. bummer. i’m running php 5.2.0.

    i tried removing E_STRICT. still doesn’t help. bummer. i’m running php 5.2.0.

    1. Create a file called phpinfo.php with the following in it.
      • <?php phpinfo();

      That will tell you the location of the server’s php initialization file. It’ll look like this:

      • Windows – Configuration File (php.ini) Path C:\WINDOWS\php.ini
      • Unix – Configuration File (php.ini) Path /home/users/mruser/php/php.ini
    2. If you’re sure that you’re changing the right php.ini file then put the following at the very end of your php.ini file:
      • display_errors = Off
    3. If that doesn’t work…(i.e. you can’t edit the php.ini file), most webservers let you put your own php.ini You’ll probably have to talk to support to figure it out.

    I’m also having a similar issue and getting the same kind of error messages, and it seems to have happened after upgrading from 2.1 to 2.1.1

    I’ve inspected the relevant files in wp-includes, and there doesn’t seem to be any extra whitespace around the opening and closing tags. I’m wondering what else changed between v2.1 and 2.1.1 to cause this.

    Do you have a plugin named Subscribe2Comments?

    I had this plugin, and it was unsuitable with WP 2.1. I just deactivated the plugin, and now I dont get this error anymore.

    I am also getting this issue

    Warning: Cannot modify header information – headers already sent by (output started at D:\Program Files\xampp\htdocs\wwitsblog\wp-login.php:1) in D:\Program Files\xampp\htdocs\wwitsblog\wp-includes\pluggable.php on
    line 275

    Trying to set a theme development rig running on Xampp (php mysql) and Vista. Tested with IE7, Opera and Firefox. I’m not running iis. Nothing but problems with this setup so far. Joomla, phpbb and gallery are running sweet on this set up. So why the problems?

    Lots like there’s an issue with following and various header issues.

    Line 275

    if ( !function_exists(‘wp_redirect’) ) :
    function wp_redirect($location, $status = 302) {
    global $is_IIS;

    $location = apply_filters(‘wp_redirect’, $location, $status);

    if ( !$location ) // allows the wp_redirect filter to cancel a redirect
    return false;

    $location = preg_replace(‘|[^a-z0-9-~+_.?#=&;,/:%]|i’, ”, $location);
    $location = wp_kses_no_null($location);

    $strip = array(‘%0d’, ‘%0a’);
    $location = str_replace($strip, ”, $location);

    if ( $is_IIS ) {
    header(“Refresh: 0;url=$location”);
    } else {
    if ( php_sapi_name() != ‘cgi-fcgi’ )
    status_header($status); // This causes problems on IIS and some FastCGI setups
    header(“Location: $location”);
    }
    }
    endif;

    By the way WordPress runs sweet on the live server (host).Has any one found a solution to this yet.

    I had this issue, but it has been resolved.

    First, I disabled all plugins and activated them one by one. After activating each one, I refreshed the pages that gave me the error(s). It wasn’t long before I narrowed down on the problematic one and disabled it. The incompatible plugin happened to be Hello Dolly.

    I found the trouble:

    first, take the space between define & ( — define (‘WPLANG’, ”);–
    then, take the / away from the coments:

    // chosen language must be installed to wp-includes/languages.
    // For example, install de.mo to wp-includes/languages and set WPLANG to ‘de’

    that’s it 🙂

    My ISP recently upgraded to WP 2.3.1 and then this error cropped up.

    I disabled Google Sitemaps plugin and the errors went away.

Viewing 15 replies - 1 through 15 (of 17 total)
  • The topic ‘Cannot modify header information – headers already sent by…’ is closed to new replies.
Skip to toolbar