// Get data From data base in php mysql
<?php
$con=mysql_connect("localhost","root","");
$db=mysql_select_db("bnr");
$sql="select *from reg";
$query=mysql_query($sql);
while($row = mysql_fetch_array($query))
{
$username=$row['username'];
echo $row['username']
echo $row['name']
echo $row['password']
echo $row['emp_id']
echo $row['phone_no']
echo $row['email_id']
echo $row['address']
}
mysql_close($con);
?>
<?php
$con=mysql_connect("localhost","root","");
$db=mysql_select_db("bnr");
$sql="select *from reg";
$query=mysql_query($sql);
while($row = mysql_fetch_array($query))
{
$username=$row['username'];
echo $row['username']
echo $row['name']
echo $row['password']
echo $row['emp_id']
echo $row['phone_no']
echo $row['email_id']
echo $row['address']
}
mysql_close($con);
?>
<html>
<head></head>
<body>
</body>
</html>
No comments:
Post a Comment