mysql_insert_id() is a PHP function, not a MYSQL function. You are also
missing a close quote on your insert string. So you have to do it like
this:
$sql2 = insert into acl (adminId,transportId,securityId) values
('$userid',.last_insert_id().,'1');
Notice the string.function().string -- this
mysql_insert_id() is a PHP function, not a MYSQL function. You are also
missing a close quote on your insert string. So you have to do it like
this:
Correct, but LAST_INSERT_ID() is a MySQL function which is what he's
using...
$sql2 = insert into acl (adminId,transportId,securityId)