Im going to get started.
Im setting up an hwid login for my vb.net program,
To be safe, im not directly connecting to my db from the program, because if it was cracked, my db info is leaked,
so i want it running through php,
this is my current php code
<?php
$con = mysql_connect("localhost","username","password");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("db", $con);
$hwid
$result = mysql_query("SELECT Name FROM hwid WHERE HWID =".$hwid. "'");
while($row = mysql_fetch_array($result))
{
echo $row['Name'] . " " . $row['HWID'];
echo "<br />";
}
mysql_close($con);
?>
`
of course, i have removed my db info, but im getting this error
Parse error: syntax error, unexpected T_VARIABLE in db.php on line 10
I cant seem to find what the problem is,
what i want to do is have the program submit the hwid like this site.com/db.php?hwid=hwid here and have it echo the name in the row of the hwid submitted.
Im kinda stumped :/
Let’s take a look at the code:
The 9th line is
$hwid, which serves no purpose. It a minimum, I would imagine it should be$hwid;. Without the semicolon the parses will continue onto the next token (on line 10) and try to understand that. It can’t, hence an error.EDIT Taking the code from your comment
The 10th line is incorrect, you’re mixing up
",'and.Try either:
or