Exemplo n.º 1
0
if (isset($_POST['add_inventory'])) {
    // Update old record
    if (isset($ID)) {
        $results = $inventory->inv_update($_POST, $ID);
    } else {
        // Insert new
        $results = $inventory->inv_insert($_POST);
    }
    if ($results) {
        echo 'Success';
    } else {
        echo 'Error';
    }
}
if (isset($ID)) {
    $inventory_result = $inventory->inv_get($ID);
}
?>
<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<title>Add Inventroy</title>
</head>
<body>

<?php 
include ABSPATH . 'include/menu.php';
?>
<hr>
	<h2>Add Inventory</h2>