prepare("INSERT INTO posts (user_id, text_content, image_path) VALUES (:user_id, :text_content, :image_path)"); $stmt->execute([ ':user_id' => $user_id, ':text_content' => $text_content, ':image_path' => $image_path ]); header("Location: ../index.php"); exit(); } ?>