This topic is locked

Error

2/28/2017 11:41:13 AM
PHPRunner General questions
M
monoofy author

I use the following code as event after successful register.



$sql = "INSERT INTO fse_ugmembers (UserName, GroupID) values ($userdata["username"], $userdata["grade"])";

CustomQuery($sql);



but it doesn't add the values to the mentioned table.

Also, gives an error after registration.
BR,

Mahmoud

S
stiven 2/28/2017


// use quotes for the values try this
$sql = "INSERT INTO fse_ugmembers (UserName, GroupID) values ('".$userdata["username"]."', '".$userdata["grade"]."')";

CustomQuery($sql);