I keep getting a syntax error and I don’t know whats wrong. Can I not call a predetermined string?
$sqlstring= "INSERT INTO friends (friend_id , friend_email , password , profile_name , date_started , num_of_friends)
VALUES (NULL , $email, $password, $name, CURDATE() , 0);";
if
$email, $password, $nameare all varchar or string,you need to wrap themwith single quote.your query is vunerable with
SQL Injection, please take time to read the article below to protect fromSQL Injction