<?php ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);if(file_exists('../../../'.$_REQUEST['tenant'].'/config.php')){require_once('../../../'.$_REQUEST['tenant'].'/config.php'); }
if(file_exists('/config.php')){require_once('/config.php');}
if($_REQUEST['type']=='itemdetails'){
$notes=str_replace("'","$#39;",$_REQUEST['notes']);
$notesave=mysqli_query($GLOBALS['con'],"UPDATE `itemdetails` SET `itemnotes`='".$notes."' WHERE `itemnumber`='".$_REQUEST['item']."'")or die(mysqli_error($GLOBALS['con']));
echo "success ".$_REQUEST['item'];
}
if($_REQUEST['type']=='locations'){
$notes=str_replace("'","$#39;",$_REQUEST['notes']);
$notesave=mysqli_query($GLOBALS['con'],"UPDATE `locations` SET `locnotes`='".$notes."' WHERE `locnumber`='".$_REQUEST['location']."'")or die(mysqli_error($GLOBALS['con']));
echo "success ".$_REQUEST['locnumber'];
}
?>