Forum Moderators: coopster
I know you can get an autonumber lookup for MySql so that the form details get pushed onto the next free space (is it auto-incrementing?) and thats what I need. Does anyone know how to do it?
Alternatively, I thought I could use the date and time as the key, but the only format I know for the date and time is:
$todayis = date("l, F j, Y, g:i a") ;
which doesn't work as it brings up "Friday, February 9, 2007, 10:39 am [EST]" (Not a good key!) Does anyone know how to change the date= to make it usable as a key?
Thanks
Yep, just use an auto increment field as you stated:
CREATE TABLE emaildata (
id int unsigned NOT NULL auto_increment,
email varchar(250) not null default '',
name varchar(250) not null default '',
PRIMARY KEY (id)
) TYPE=MyISAM;
Adjust to suit. Something like that maybe? Its easier when deleting info too as each id will be unique.
dc