Image is displaying all the fields with data coming from database but in the image field it is saying no file chosen.我正在尝试获取具有特定列(例如title,slug和image)的行。但是我无法获取特定ID的图像。 所有字段都从数据库获取数据。但是图像失败了。 当前代码如下:-
enter code here
if (isset($_GET['piD'])) {
$piD = $_GET['piD'];
$fetch = $conn->prepare("SELECT * FROM posts WHERE id=?");
$fetch->execute(array($piD));
if ($fetch->rowCount()>0) {
$postRow = $fetch->fetch();
$title = $postRow['title'];
$email = $postRow['email'];
$slug = $postRow['slug'];
$body = $postRow['body'];
$image =$postRow['image'];
}
else
{
header('location:posts.php?no post found');
}