WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Warning: Cannot modify header information (8 posts)

  1. cableghost
    Member
    Posted 3 years ago #

    Okay, so I know there's a ton of content and solutions out there, which I have spent a fair amount of time investigating. However, I have yet to find a solution.

    Though the following error is revealed, the action I was looking to take place executes fine and there is nothing 'visually' wrong with the site.

    Suggestions?

    Warning: Cannot modify header information - headers already sent by (output started at /home/xxxxxx/public_html/xxxxxx/wp-content/themes/fiono/functions.php:366) in /home/xxxxxx/public_html/xxxxxx/wp-includes/pluggable.php on line 897

    Line 897: header("Location: $location", true, $status);

    I have checked and rechecked numerous php files and they do not seem to have any white space problems. If this is truly a header issue, I'm miffed, as this error just occurred without any modifications to the files identified, or any of the theme files.

    I also receive a similar error for line 99 of theme-editor.php

    Thanks, Scott

  2. esmi
    Forum Moderator
    Posted 3 years ago #

    output started at /home/xxxxxx/public_html/xxxxxx/wp-content/themes/fiono/functions.php:366

    Try looking in the theme's functions.php file.

  3. cableghost
    Member
    Posted 3 years ago #

    I have opened it numerous times...what exactly should I be looking for?

    functions.php: http://pastebin.com/zWTY2XhB

    I did add the last php in that file, but removing it does not make a difference, so the issue is elsewhere.

    -Scott

  4. esmi
    Forum Moderator
    Posted 3 years ago #

    Look at line 366

  5. cableghost
    Member
    Posted 3 years ago #

    Pardon my ignorance...do I not need the <?php?

  6. esmi
    Forum Moderator
    Posted 3 years ago #

    That depends if it's preceded by a closing ?>

  7. cableghost
    Member
    Posted 3 years ago #

    I decided to remove the php statement, and now I get the same error for line 99 of theme.editor.php

    http://pastebin.com/M32qRABX

    I see that line 99 has something to do with headers

    header("Location: $location");

    However, I am unable to diagnosis the actual issue.

    -Scott

  8. cableghost
    Member
    Posted 3 years ago #

    Update: a browser restart and the issue appears to be gone. I will mark this thread resolved in a few days if there's no relapse.

    Thanks @esmi for the input.

Topic Closed

This topic has been closed to new replies.

About this Topic