The div that I want the image to be displayed in (form is sent to send_post.php):

Code:
<div style="width:200px ; height: 200px ; border:1px dashed red ; display:inline-block ; margin-top:5px ; margin-left:5px" class="postedBy"></div><!--end image-->
Code from send_post.php:

Code:
<?php

session_start();

    if(!isset($_SESSION['username']))   {
    header('location: mustLogin.php');
} else  {
    $username = $_SESSION['username'];
}

$title = $_POST['title'];
$description = $_POST['description'];
$image = $_POST['image'];
$dateAdded = date('Y-m-d');
$addedBy = $username;

if (!empty('title') && !empty('description') && !empty('image')) {
//establish connection to SQL
$conn = mysqli_connect("localhost", "root", "") or die ("Couldn't connect to SQLI");
//connect to DB
mysqli_select_db($conn, "accounts") or die ("Couldn't find DB");

$sqliCommand = "INSERT INTO `posts` (title, description, image, date_added, added_by) VALUES ('$title', '$description', '$image', '$dateAdded', '$addedBy')" or die ('Info couldnt go to database');

mysqli_query($conn, $sqliCommand) or die ('MySQLI error');

header('location: profile.php?user='.$username);

} else  {

    header('location: error.php');
}
The info get's sent to the database just fine, but can someone explain to me how I can get the images added by the user (all of them) to display in the first div I listed?

So far for displaying the image in the div I have:

Code:
$conn = mysqli_connect("localhost", "root", "") or die ("Couldn't connect to SQLI"); mysqli_select_db($conn, "accounts") or die ("Couldn't find DB"); $sqli = ("SELECT image FROM posts WHERE added_by = '$username'"); $result = mysqli_query($conn, $sqli);
But I don't know if that's correct, and if so, I don't know where to go from here.
any help iis appreciated.