Problem creating temporary table

Can somebody please tell me what is stopping this script from running please.

             $newtable = mysql_query("CREATE TEMPORARY TABLE maillist
                 (emailid int not null PRIMARY KEY,
                 customerfirstname varchar(255) not null,
                 customersurname varchar(255) not null,
                 email varchar(255) not null)");

When I try to run it it does not seem to do anything, and as the connection is not being closed I do not think it is being created and then dropped immediately.

If the word ‘TEMPORARY’ is left out then the table is created no problem.

Temporary tables exist for the duration of the connection which they were created. So have you tried checking for its existence with another query right below that one?

Thanks for that. Should have thought of a basic check like that myself!!!
Conclusion: the table is being created and the connection being interupted before I try to access the data in it.