Problem with blog coding

Posted on 2013-01-29
Last Modified: 2013-03-01
Hi there. I have a wordpress blog and I see this error message on the top when I login...

how do i fix this

Warning: Cannot modify header information - headers already sent by (output started at /home/sling15/public_html/ in /home/sling15/public_html/ on line 876

i use the thesis theme so if anyone have info on how to fix this that will be good
Question by:slingingshot15
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
LVL 11

Expert Comment

ID: 38834770
add ob_start(); in both of the pages wich are throwing the error message.

That's because you send something to the client before all php code has been executed and this is against w3c standards that headers must be sent before any content and only in this order headers->content.

Author Comment

ID: 38834788
how do i do that? where do i go?
LVL 11

Accepted Solution

mcnute earned 250 total points
ID: 38834819
You do that by going in your wordpress backend as wp-admin. Go to the theme tab and edit these two documents in the wordpress web editor:

or you open a connection with an ftp client such as filezilla, browse to the directory wp-includes/ and right click on the two files, choose download and edit.
This will open the two files in your defined editor or default editor of php files on your system, and there you can add ob_start(); just on top of the two files, save and upload them again.
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

LVL 70

Expert Comment

by:Jason C. Levine
ID: 38852269
The problem is being caused by a bad plugin or theme file.  Mcnute's answer, while it will work (except you can't edit the core from the backend, need to use FTP), involves changing core WordPress files and as soon as WordPress updates the changes will be lost and the problem will return.

You would be better off isolating the problem file by deactivating all plugins and then reactivating one at a time until the problem reappears or searching through the theme to see where headers are being sent and attempting to comment out those lines.

Author Comment

ID: 38874242
how do i search through the theme to see where headers are and comment them out...

how do i do that???
LVL 70

Assisted Solution

by:Jason C. Levine
Jason C. Levine earned 250 total points
ID: 38878706
You need to download the theme from the server and search using a tool that can search across whole folders (Programmer's Notepad, etc) for the PHP header command.

Featured Post

How our DevOps Teams Maximize Uptime

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us. Read the use case whitepaper.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is intended for those who are new to PHP error handling (  It addresses one of the most common problems that plague beginning PHP develop…
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
The purpose of this video is to demonstrate how to set up an RSS Feed on a WordPress Website. This will be demonstrated using a Windows 8 PC. Feedburner will be used for this demonstration. Go to your WordPress login page. This will look like the…
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

736 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question