magic-fields-team / Magic-Fields-2

Magic Fields 2.X
http://magicfields.org
GNU General Public License v2.0
123 stars 47 forks source link

"Warning: Cannot modify header information" after deleting a Post ( MF2 - Custom Post Type) #230

Closed KevinR23 closed 10 years ago

KevinR23 commented 10 years ago

Hey Guys,

in almost every wp-site i get the warning

Warning: Cannot modify header information - headers already sent by (output started at /var/www/web252/html/finearbeit/wp-content/plugins/magic-fields-2/admin/mf_post.php:503) in /var/www/web252/html/finearbeit/wp-includes/pluggable.php on line 1121

this is my post-type https://www.dropbox.com/s/fkz3p0d29kt2nzm/Screenshot%202014-06-05%2012.21.32.png

i tested a complete new installation just with magic fields 2. same warning!

the delete-process is fine, but i get the warning.

1) I delete a mf custom post type 2) i get the warning 3) i press back 4) i press reload 5) the post is gone.

same, when i want to restore the post out of the trash.

The Problem exists since WP 3.9 in all my installations with magic fields. Anyone a clue?

thanks Kevin

KevinR23 commented 10 years ago

Okay, after another Day of searching i got it:

1- Download wp-config.php from your server. 2- Open Notepad++ (really you don't have it?) open wp-config.php At last of wp-config.php eraser the code ;> if it writing there. 3- Go to menu Enconding and select 'Enconde in UTF-8 without BOM'. 4- Uploading wp-config.php to your server.

AND!

I added <?php ob_start(); ?> to the first line of my functions.php in my theme