i want to insert data through loop in mysql table but it insert only a time when loop execute where i want to insert 500 Times the same data into my table below are the codes thanks in advance
enter code here
<html>
<head>
</head>
<body>
<div>
<?php
$con=mysqli_connect("localhost","root","khan","first");
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
for($i=1;$i<500;$i++)
{
$sql="INSERT INTO bio(name, fathername , address) VALUES('khan','khan','khan')";
echo "Number " . $i . "<br>";
}
if (!mysqli_query($con,$sql))
{
die('Error: ' . mysqli_error($con));
}
mysqli_close($con);
?>
</div>
</body>
</html>