How to use headers_sent() function to check whether header have been sent or not in PHP

1 Answer

0 votes
if (!headers_sent()) 
{
    header('Location: http://www.collectivesolver.com/');
    exit;
}

   
/*
run: 

open collectivesolver.com

*/

 



answered May 11, 2016 by avibootz

Related questions

1 answer 170 views
4 answers 222 views
2 answers 247 views
1 answer 159 views
...