Пример #1
0
function addbooking()
{
    require_once "booking.php";
    $userid = $_REQUEST['userid'];
    $time = $_REQUEST['time'];
    $provider = $_REQUEST['providerid'];
    $obj = new booking();
    if (!$obj->addbooking($userid, $time, $provider)) {
        echo '{"result":0,"message:"error making booking"}';
    } else {
        echo '{"result":0,"message:"Booking made successfully"}';
    }
}