Hello this is Ticker

Header Already Send | PHP Error | Solution

How to resolve header already sent error in PHP


php header main.jpg

PHP redirect error says already sent header information can not change.

Header error in PHP is most probably an error comes when we move our website on the server and then we saw this error because we have input some HTML text or element before the header redirect. We can resolve this error easily by changing the code for the header (location or URL) before the HTML text or element.


php header 11.jpg

PHP Code


<php
// With Error
echo"<p>Not send</p>";
header("location:index.php");

// Without Any Error
header("location:index.php");
echo"<p>Not send</p>";
?>


php header 13.jpg

This the simple method to resolve the PHP header already sent error. For more information regarding programming and solution visit the different blogs on our website and learn coding from hacker console.



  Jai Kumar  PROGRAMMING