i am driving myself crazy over this and i have no idea why this doesnt work.
I'm learning sql anbd this is my 2nd ever script involving sql so can somebody PLZ tell me what the hell is wrong with this.I dont get any error message, but nothing happens to the database.Nothing is inserted what so ever.
<?php
$auser = $POST["user"];
$apass = $POST["pass"];
$user = "root";
$password = "*******";
$database = "phptest";
mysql_connect(localhost,$user,$password);
mysql_select_db($database) or die( "Unable to select database");
$query ="insert into work values (0,$auser,$apass,4)";
mysql_query($query);
?>
Surely that should insert into table work what the user typed in in the page before. But nothing happens. absolutely nothing. help would be appreciated a LOT. Thank you .