hello all,
I am neck deep in this sucker... basically here it is.
I am trying to set some session variables and when the redirect happens, they are lost.
here is my code:
function addItem ($itemId, $url){
$hostname_attain = "";
$database_attain = "";
$username_attain = "";
$password_attain = "";
$attain = mysql_pconnect($hostname_attain, $username_attain, $password_attain) or trigger_error(mysql_error(),E_USER_ERROR);
$colname_Recordset1 = "-1";
if (isset($itemId)) {
$colname_Recordset1 = (get_magic_quotes_gpc()) ? $itemId : addslashes($itemId);
}
mysql_select_db($database_attain, $attain);
$query_Recordset1 = sprintf("SELECT * FROM eccommplan WHERE commPlanId = %s", $colname_Recordset1);
$Recordset1 = mysql_query($query_Recordset1, $attain) or die(mysql_error());
$row_Recordset1 = mysql_fetch_assoc($Recordset1);
$totalRows_Recordset1 = mysql_num_rows($Recordset1);
session_start();
$_SESSION[$itemId][1] = $itemId;
$_SESSION[$itemId][2] = $row_Recordset1['commPlan'];
$_SESSION[$itemId][3] = $row_Recordset1['commPlanPrice'];
mysql_free_result($Recordset1);
session_write_close();
header("Location: $url");
}[/COLOR]
I have tried all the fixes that are on php.net and still nothing. I am sure that someone out there has run into this issue before... if anyone has a solution, I would love to get this working! :glare: