<?php
include("configa.php");

if (isset($_POST['id'])) {
    $id = intval($_POST['id']);
    $sql = "DELETE FROM final_order_item WHERE id = $id";
    if (mysqli_query($conn, $sql)) {
        echo "success";
    } else {
        echo "error: " . mysqli_error($conn);
    }
} else {
    echo "invalid";
}
?>
