Jump to content

Having a problem with a storing a variable to a session


jim.davidson

Recommended Posts

I have a form that the user selects a date and member id.  I then update a table with that info and store the date to a session variable for use on another page.  Everything works except the date doesn't store to the session variable.  I can't see what I'm doing wrong.

 

Heres the code, any help will be greatly appreciated!

 

if( is_array($member)){

  $ddate = explode('/', $_POST['meeting_date']);

  $sql_meeting_date = "$ddate[2]-$ddate[0]-$ddate[1]";

  $_SESSION['meeting_date'] = $sql_meeting_date;

  while (list ($key, $val) = each ($member)) {

    $insertSQL = sprintf("INSERT INTO meetings (member_id, date) VALUES (%s, %s)",

      GetSQLValueString($val, "int"),

      GetSQLValueString($sql_meeting_date, "date"));

      mysql_select_db($database_myvfd, $myvfd);

      $Result1 = mysql_query($insertSQL, $myvfd) or die(mysql_error());

  }

}

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.