<?php
session_start();
header('Content-Type: application/json');

if (isset($_SESSION['food_items'])) {
    unset($_SESSION['food_items']);
    echo json_encode(['status' => 'success']);
} else {
    echo json_encode(['status' => 'error', 'message' => 'No session data found.']);
}
?>
