I've gotten a little confused with the PDO::prepare functions.
I have something like this
array('user_email'=>'[email protected]','user_pass'=>'password')
and i'd like to translate it into something like this
INSERT INTO user_info (user_email, user_pass) VALUES ([email protected], password)
using parameterized queries with PDO (or mysqli, I'm open to suggestions). Another idea -
array('uid'=>'10', 'first_name'=>'robert', 'last_name'=>'jones')
array("email", "number")
into
SELECT email, number FROM t1 WHERE uid=10 AND first_name=robert AND last_name=jones
I know the answer lies somewhere with PDO::prepare
and call_user_func_array
, but I've gotten really confused on how the latter function works, and would appreciate an explanation.
Thanks a ton!