session - PHP header working on localhost but not on live server
827
this is my php page.. if anyone directly visits this page it will read session if the value is not set then value and redirect to page.html. else it will print some message. this is working on local host but not on live server.
<?php
session_start();
$name = $_SESSION['team']; //a value stored in session which i used on this page
if (($_SESSION["abc"] !== 'good')) {
header('Location: http://www.abc.com/page.html');
}
else{
echo $name. 'you have completed register process part one you may continue!';
}
?>
Answer
Solution: