Hi everybodye 🙂
I'm trying to store data into a database called "prijslijst" and in a tabel called "test". I use session_start and the PHPSESSID command, so that everybody has a own place in de table. But when i add the informatie into the form once everything goes ok. but when i try it for the second or third.... time there isn't any data added to the database ..what am i doing wrong?...
the script:
------begin--------
<?php
session_start();
session_register("ids");
$ids=$PHPSESSID;
mysql_connect("localhost","","");
mysql_select_db("prijslijst");
print "";
print "<head>";
print " <title>Untitled</title>";
print "</head>";
print "<body>";
print "<form action=test.php method=post>";
print "naam: <input type=text name=naam>";
print "produkt: <input type=text name=produkt>";
print "<input type=hidden name=id value=$ids>";
print "<input type=submit value=ok>";
print "</form>";
print "<br> uw id is : $ids ";
print "</body>";
print "";
$sql = "insert into test (id, naam, produkt) values ('$id', '$naam', '$produkt')";
mysql_query($sql);
?>
-------end--------
THANX!