ESH/delete_training_details.php
2024-10-23 18:28:06 +05:30

32 lines
848 B
PHP

<?php
error_reporting(E_ERROR | E_PARSE);
include('includes/config/config.php');
include ('includes/functions.php');
include ('log_entry.php');
error_log ( "Start Printing Request Attributes" );
$requestStr="";
foreach ( $_REQUEST as $key => $value ) {
$requestStr.=$key . " : " . $value . "\n";
error_log ( $key . " : " . $value . "<br />\r\n" );
}
error_log ( "End Printing Request Attributes" );
save_log($requestStr,'Training List','DELETE','delete_training_details.php');
$training_id=$_REQUEST['training_id'];
//echo $training_id;
if(!empty($training_id)){
//update case
$query="delete from training_master where training_master_id='$training_id'";
$result = @mysqli_query($conn,$query);
}
if (!$result) {
exit(mysqli_error($conn));
echo json_encode("FAILURE");
}
else
{
echo json_encode("SUCCESS");
}
?>