<?php 
	require_once('../Connections/conn_ama.php'); 
	include("../../../../../../functions/functions.php");
	$curr_time = date("Y-m-d H:i:s");    
	    
	if (!isset($_SESSION)) {
	  session_start();
	}

	if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "save-doc-category")) {

		$insertSQL = sprintf("INSERT INTO doccategories(category, `description`) VALUES ( %s, %s)",
						   	GetSQLValueString(trim($_POST['category']), "text"),
	                       	GetSQLValueString($_POST['description'], "text"));

	  	$Result1 = mysqli_query($conn_ama, $insertSQL) or die(mysqli_error($conn_ama));
	  		//$articleID = mysqli_insert_id($conn_ama);	

		  if($Result1){
		  	//List the uploaded article via the articleID
		 
				  echo "datasent";
			}

			else{
				echo "notset";
			}
	}
 ?>