Hello, before you say "noob" i really bad in php.
I want to create a additem script BUT IT IS REALLY BAD.
I search bij CID.
This is my script:
PHP Code:
<center>
<form method="post" action="<? echo $PHP_SELF;?>">
<p><b>CID:</b>
<input type="text" name="cid" />
</p>
<p>
<input type="submit" value="Search" name="zoek" />
</p>
</form></center>
<?
$host = "";
$user = "sa";
$pass = "";
$dbname = "GunzDB";
$itemid = "3165";
$thanks = "Thank you. To add this item to your character!";
$connect = odbc_connect("Driver={SQL Server};Server={$host}; Database={$dbname}", $user, $pass) or die("Cant't connect the Server.");
$cid = $_POST["cid"];
$query = odbc_exec($connect,INSERT INTO [CItemTable]} (CID, ItemID) VALUES ('$cid', '$itemid');
odbc_fetch_row($query);
if( isset($_POST['zoek']) )
{
if (empty ($cid))
{
echo("<font color=\"red\"><h1><center>Enter something!</h1></center></font>");
}
else
{
echo ($thanks);
}
}
?></b>
</div>
I'am really bad in php.
Error:
Code:
Parse error: syntax error, unexpected T_STRING in C:\wamp\www\itemcheck.php on line 20

Really normaly an error
Please help me.
Please dont post messages like: "you are noob" "learn php"