Warning: mysql_query() expects parameter 1 to be string
<p>Error:Warning: mysql_query() expects parameter 1 to be string, resource given in C:\wamp\www\cdij\editquantity.php on line 8</p>

<p>Here is the Code:</p>

<pre><code>&lt;?php
$con=mysql_connect("localhost","root","","test");
$quantity=$_POST['txt_quantity'];
$name=$_POST['Fields'];
$table=$_POST['editwhat'];

$que="UPDATE `material` SET `material_quantity`='".$quantity."' WHERE `material_name`='".$name."'";
mysql_query($con,$que);
mysql_close($con);
?&gt;
</code></pre>
