K im trying to upload a .txt to a database heres the coding.
The Form
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<form action="result.php" method="post" enctype="multipart/form-data" name="form1">
<input type="file" name="file">
<br>
<input type="submit" name="Submit" value="Submit">
</form>
</body>
</html>
The result.php this file is what makes it upload to the database
<?
//Connect to mysql server
$con = mysql_connect("localhost","user","pass");
mysql_select_db("nba",$sql_id);
$result = mysql_db_query('$sql_id',"LOAD DATA LOCAL INFILE 'export_file_name.txt' INTO TABLE stats FIELDS TERMINATED BY ',' ENCLOSED BY '\"'") or die ("Invalid DATA LOAD query");
?>
what i get is invalid dataload. I cant find out what is wrong