I dont understand why I am getting this SQL error
Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'strlvl = 4', `strdmg` = 1, `strxp` = 0, `strdiv` = 1, `dexlv
I have tried using the tag's around the values (1, 0 1 etc..) it does not work though
$c = mysql_connect("localhost","root","");
if (!$c)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("chars", $c);
$tcn=$_POST['username'];
$s="INSERT INTO chars SET
`charname` = $tcn,
`strlvl` = 4,
`strdmg` = 1,
`strxp` = 0,
`strdiv` = 1,
`dexlvl` = 4,
`dexcth`= 0,
`dexxp` = 0,
`dexdiv` = 1,
`currlife` = 13,
`maxlife` = 13,
`deflvl` = 2,
`defxp` = 0,
`defda` = 0,
`intlvl`= 4,
`intxp` = 0,
`foclvl`= 4,
`focxp` = 0,
`mag`= 13,
`weapon`= Fists,
`charname` = Fists,
`spell` = Shockwave,
`spelltype` =lightning,
`gold` = 0,
`bankedgold` = 10";
if (!mysql_query($s,$c))
{
die('<font color="blue" size="3"><i> Error: ' . mysql_error()) . '</font></i>';
}