Skip to main content
deleted 50 characters in body
Source Link

I am not sure if this will help... but I found that I had some code in a template and I was starting with get_header() in this way:

<?php
/**
 * .. Template comments
 */

 get_header();

 if(...) {
    ...
    if(...) {
      ...
      wp_redirect($url);
      exit();
    }
 }
 ?>

and was getting the same issue of header previously sent... What I did was just move get_header() to the end of the block and voila!!!

<?php
/**
 * .. Template comments
 */


 if(...) {
    ...
    if(...) {
      ...
      wp_redirect($url);
      exit();
    }
 }
 get_header();
 ?>

No plugin was disabled. and everything was ok... you may give a try if this works for you

I am not sure if this will help... but I found that I had some code in a template and I was starting with get_header() in this way:



    

and was getting the same issue of header previously sent... What I did was just move get_header() to the end of the block and voila!!!



    

No plugin was disabled. and everything was ok... you may give a try if this works for you

I am not sure if this will help... but I found that I had some code in a template and I was starting with get_header() in this way:

<?php
/**
 * .. Template comments
 */

 get_header();

 if(...) {
    ...
    if(...) {
      ...
      wp_redirect($url);
      exit();
    }
 }
 ?>

and was getting the same issue of header previously sent... What I did was just move get_header() to the end of the block and voila!!!

<?php
/**
 * .. Template comments
 */


 if(...) {
    ...
    if(...) {
      ...
      wp_redirect($url);
      exit();
    }
 }
 get_header();
 ?>

No plugin was disabled. and everything was ok... you may give a try if this works for you

Source Link

I am not sure if this will help... but I found that I had some code in a template and I was starting with get_header() in this way:



    

and was getting the same issue of header previously sent... What I did was just move get_header() to the end of the block and voila!!!



    

No plugin was disabled. and everything was ok... you may give a try if this works for you