require_once 'autoload.php'; $_SESSION['LAST_ACTIVITY'] = time(); $toolbody = new Toolbody(); if (isset($_POST['tooldesc'])) { print_r($_POST); //print_r($_FILES); if (isset($_POST['ToolBody_ID'])) { $toolbody->setToolBodyID($_POST['ToolBody_ID']); $toolbodyid = $_POST['ToolBody_ID']; } else { $toolbodyid = ''; } ///get tool_id if we are editing an existing tool. $toolbody->setToolDesc($_POST['tooldesc']); $toolbody->setMfgPartNO($_POST['mfgpartno']); $toolbody->setTypeID($_POST['ToolBody_Type_ID']); if (isset($_POST['cdiameter'])) { $toolbody->setCdiameter($_POST['cdiameter']); } if (isset($_POST['ndiameter'])) { $toolbody->setNdiameter($_POST['ndiameter']); } if (isset($_POST['sdiameter'])) { $toolbody->setSdiameter($_POST['sdiameter']); } if (isset($_POST['flutelength'])) { $toolbody->setFluteLength($_POST['flutelength']); } if (isset($_POST['reach'])) { $toolbody->setReach($_POST['reach']);