I am trying to populate a SQL entry with data from a php script but it doesnt work. I have the config file set up right and everything. This is the code I have
<?
include_once "secure/dbconfig.php";
//check md5
$SECRET = 'xxxxxxxxxxxxxxxxxxxxxxxxx';
$sig = md5('userId'+":"+'appId'+":"+'SECRET');
if($_REQUEST['sig'] == $sig) {
$userdata = GetUserInfo($_REQUEST['userId']);
$conn = ConnectDB();
$res = mysql_query('UPDATE users SET points + '.$_REQUEST['amount'].' WHERE id = '.$_REQUEST['userId'].''. $connection);
if($res){
print "1";
}else{
print "0";
}
}else{
print "0";
}
How would I set up the SQL database in detail?