title: PHP image still displaying after deleted
body: <p>I'm using a long form to update advertisements in my database. I also use this form to delete images by pressing the delete button. The delete progress works fine, it removes the image's path from the database but the image is still displaying until I manually reload the page. I tried to echo a javascript reload code in the end of the isset method, but it keeps reloading infinitely.</p>
  <p>My code:</p>
  <pre><code>// Delete image
  if (isset($_POST['delete'])) {
      $delete_imageid = $_POST['imageid'];
      $stmt = $link-&gt;prepare(&quot;DELETE FROM images WHERE id = ?&quot;);
      $stmt-&gt;bind_param('i', $delete_imageid);
      $stmt-&gt;execute();
      $stmt-&gt;close();
  
  }
  </code></pre>