title: Session not working on wamp but works on live server
body: <p>I have this code and I have tried everything i can think of to get it to work on my WAMP local server any help would be greatly appreciated. I am PHP stupid. This works on a live server but not my WAMP server. I do get logged in just the pages do not seem to be passing the session variable to the proper user level. That's what's not working sorry for the poor description the first time.</p>
  
  <pre><code>if(!empty($_SESSION['LoggedIn']) &amp;&amp; !empty($_SESSION['login']))
   {
  if ($level == "Administrator") {
  
  echo 'My Content';
  }
  
  elseif ($level == "Bank Officer") {
  echo "";
  }
  
  elseif ($level == "Agent") {
  echo "";
   }
  
  elseif(!empty($_POST['login']) &amp;&amp; !empty($_POST['password']))
  {
  $login = mysql_real_escape_string($_POST['login']);
  $password = $_POST['password'];
  
  
  $checklevel = mysql_query("SELECT * FROM users WHERE login = '".$login."' AND password = '".$password."' ");
  if(mysql_num_rows($checklevel) == 1)
  {
      $row = mysql_fetch_array($checklevel);
      $level = $row['level'];
      $_SESSION['level'] = $level;
  }
  
  $checklogin = mysql_query("SELECT * FROM users WHERE login = '".$login."' AND password = '".$password."' AND level='".$level."'");
  if(mysql_num_rows($checklogin) == 1)
  {
      $row = mysql_fetch_array($checklogin);
      $firstname = $row['firstname'];
      $login = $row['login'];
      $agent = $row['agent'];
      $_SESSION['agent'] = $agent;
      $_SESSION['firstname'] = $firstname;
      $_SESSION['login'] = $login;
      $_SESSION['LoggedIn'] = 1;
  </code></pre>
  
  <p>Thanks you for any help at all.</p>