Headers already sent – Solve
Most programmers get the warning of headers already sent in php. This warning occurs due to using header function of php. To remove the warning in your webpage simply place @ in front of header function but this stops working of header function some time. To solve this problem you can use javascript redirect function. Here is the code:-[code lang=”php”] <?php echo "<script type=’text/javascript’> <!– window.location = ‘http://www.msn.com/’ [...]
Most programmers get the warning of headers already sent in php. This warning occurs due to using header function of php. To remove the warning in your webpage simply place @ in front of header function but this stops working of header function some time. To solve this problem you can use javascript redirect function. Here is the code:-[code lang=”php”] <?php
echo "<script type=’text/javascript’>
<!–
window.location = ‘http://www.msn.com/’
//–>
</script>";
?>[/code]
Share this article
Written by : Junaid Rehman
I am a blogger and freelance web developer by profession. I love to blog and learn new things about programming and IT World.
Follow us
A quick overview of the topics covered in this article.
Latest articles
February 14, 2025
February 14, 2025
February 14, 2025
February 14, 2025
February 14, 2025