Forum Moderators: coopster
$sql = "INSERT INTO $table (value1) VALUES ({$_SESSION['value1']})"
Another way to do it is:
$sql = "INSERT INTO $table (value1) VALUES (" . $_SESSION['value1'] . ")"
Those are both assuming that value1 is numeric. If it's varchar, text, etc. you need quotes:
$sql = "INSERT INTO $table (value1) VALUES ('{$_SESSION['value1']}')"
or
$sql = "INSERT INTO $table (value1) VALUES ('" . $_SESSION['value1'] . "')"