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 176 views
4 answers 229 views
2 answers 257 views
1 answer 167 views
...