the 404 Not Found
error could it be because of the link:
<a class="blog_title_link" href="singlepost?ID=' . $row['postID'] . '">
__________^___
Maybe you need singlepost.php?ID...
?
And then this line too should be:
$result = mysqli_query($con,"SELECT * FROM posts WHERE postID=" . $pID);
// ___not^___but^