<?php
include("lib/db.inc");
include("lib/util.php");

//echo "HERE";
//var_dump($_POST);
extract($_POST);
$vat = 0.14;
$vat_amount =  $unit_price* $vat;
$total_cost = $vat_amount + $unit_price;
//die();

$sql = "insert into items (item_name,short_description,  long_desciption , user_id,unit_price,vat_included,var_amount,total_cost,image_name) 
values ('$item_name','$short_description','$full_description','40','$unit_price','1','0.14','$total_cost','$image_name')";
$data->execNonSql($sql);
echo $sql;
redirect("index.php?page=additem");

?>