When I log in to my website the first time after I open Chrome, my $_session variables are not available. The login works in that I get to the next page(just like I am supposed to). However, there is a title that does not display that is one of the session variables. If I try to initiate one of the options from a drop down list I get an error message about no connection to my database. Most of my scripts have a line INCLUDE “base.php”;. Here is my base script.
<?php session_start(); $con = mysql_connect($_SESSION['Host'], $_SESSION['User'], $_SESSION['Pass']) or die("MySQL Error: " . mysql_error()); $db = mysql_select_db($_SESSION['Username']) or die("MySQL Error: " . mysql_error()); ?>If I then logout and login again everything works as it should. This is only an issue with Google Chrome. My login script works perfectly on every other browser I have tried. Here is my logout script.
<?php session_start(); session_unset(); session_destroy(); header("location:http://www.mywebsite.biz/home.html"); ?>I am completely puzzled… any help is greatly appreciated