I set up all of my database information in javascript and It doesn't want to seem to connect. If it is connecting it doesn't update any data.
Here is my Query and Connection Code: Full Code: https://pastebin.com/PBMW6UM8
Query Code:
var sql = "UPDATE tf2 SET credits = ? WHERE steamid = " + mysql.escape(id)
con.query(sql, [totalcash], function (err, result) {
if (err) throw err;
});
Or look for //Query Code in Pastebin.
Extra Variables
<script>totalcash='<?php echo $credits; ?>'</script>
<script>id='<?php $steamprofile['steamid']; ?>'</script>