<?php
include "../config/db.php";

$result = mysqli_query($con, "SELECT * FROM projects");
?>

<h2>Projects</h2>

<?php while ($row = mysqli_fetch_assoc($result)) { ?>

    <div>

        <h3><?php echo $row['project_name']; ?></h3>

        <img src="../uploads/<?php echo $row['image']; ?>" width="150">

        <br>

        <a href="project_edit.php?id=<?php echo $row['id']; ?>">
            Edit
        </a>

    </div>

    <hr>

<?php } ?>