<link rel="stylesheet" href="../css/sweet-alert.css" /> 


<?php 
include("../connection.php");
include("../user.php");
$user=$_SESSION['user'];
$cur_date=date('Y-m-d H:i:s');

?>

<?php

	
	$config=$_REQUEST['config'];
	$cdec=$_REQUEST['con_dec'];
	$id=$_REQUEST['id'];
		$confg=mysqli_query($con,"UPDATE `configuration_master` SET `configuration`='$config',`config_description`='$cdec',`status`='0',`modified_on`='$cur_date',`modified_by`='$user' WHERE `id`='$id'");
		//echo "UPDATE `configuration_master` SET `configuration`='$config',`config_description`='$cdec',`status`='0',`modified_on`='$cur_date',`modified_by`='$user' WHERE `id`='$id'";
if($confg)
	{
	?>
	<script>
	
	
    setTimeout(function() {
        swal({
            title: "Successfully",
            text: "Configuration updated!",
            type: "success"
        }, function() {
      window.location = "config_master.php";
        });
    }, 100);
</script>  
    <?php
	}	
	else
	{
	?>
	<script>
    setTimeout(function() {
        swal({
            title: "Not",
            text: "Configuration updated!",
            type: "error"
        }, function() {
         window.location = "config_master.php";
        });
    }, 100);
</script> 	  
	<?Php
	}	
?>

  <script src="../js/sweet-alert.js"></script>

