setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$result_ps = $conn->prepare($sql_ps);
try {
$result_ps->execute();
while ($row_ps = $result_ps->fetch(PDO::FETCH_ASSOC)) {
// เช็คว่ามีรูปอัปโหลดไหม ถ้ามีก็ดึงมา ถ้าไม่มีก็ซ่อนกล่องนี้ไปเลย
if (!empty($row_ps['coverImg'])) {
$img_url = "../backend/uploads/personnel/" . $row_ps['id'] . "." . $row_ps['coverImg'];
?>
getMessage();
}
?>