dear friends,
I am developing Online registration form... I want to display data record vice not row code is below

include "conn1.php";

$sql = "SELECT * FROM reg";
$result = $conn->query($sql);

if ($result->num_rows > 0) {
     echo "<table style='border: solid 1px black;'>";
     echo "<tr><th>Id</th><th>Firstname</th><th>Lastname</th><th>Email</th><th>Reg date</th></tr>";
     // output data of each row
     while($row = $result->fetch_assoc()) {
        // echo "<tr><td>" . $row["pn"]. "</td><td>" .$row["sp"]. "</td></tr>";
     echo "</table>";
} else {
     echo "0 results";


please suggest me.

Re: Php database 80 80

I don't understand what you mean. What is data record vice and row vice?
What data from the table do you want to display on the screen?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.