<?php

include $_SERVER['DOCUMENT_ROOT'] . "/classes/autoload.php";


$client_id = $db->query("suppliers", "UPDATE suppliers SET `name` = '{$_POST['name']}', `address` = '{$_POST['address']}', `contact_person` = '{$_POST['contact_person']}', `contact_number` = '{$_POST['contact_number']}', `email` = '{$_POST['email']}', `code` = '{$_POST['code']}' WHERE `record_id` = '{$_POST['record_id']}'");

if ($client_id > 0) {
    header("location: home.php");
}