The following code is trying to insert into a MYSQL database from a form and pop an alert screen when the query is successful, but it's not working. I keep getting "Warning:mysql_query():supplied argument is not a valid MySQL-Link resource in c:\inetpub... on line 88". What am i doing wrong?
$sql = "INSERT into varorder (varid) VALUES(".$HTTP_POST_VARS["varid"].")";
if (mysql_query($dbconn, $sql))
{
echo"<SCRIPT>alert('Your order has been created');</SCRIPT>
}