Page is a not externally linkable
- Code, Content, and Presentation
-- Databases
---- Problem sending form data to email and insert in database


LifeinAsia - 3:55 pm on Jul 28, 2010 (gmt 0)


You don't use SET with an INSERT. You only use SET with UPDATE. INSERTS are of the form:
INSERT INTO TableName (Field1, Field2, ..., Fieldn)
VALUES (Value1, Value2, ..., Valuen)

So yours would be something like:
INSERT INTO ".$TABLES["enquiries"]." (p_id, p_name, ...)
VALUES ('".mysql_escape_string($ACC["ref"])."','".mysql_escape_string($ACC["name"])."', ...)


Thread source:: http://www.webmasterworld.com/databases_sql_mysql/4177620.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com