Currently, I am looking to convert the alert window into a template that utilizes Kendo UI for alerts. Previously, I had been using AJAX for the alert functionality.
The current alert window looks like this:
I require assistance with coding it in AJAX
AJAX PHP
//AJAX call for button
$("#primaryTextButton").kendoButton();
var button = $("#primaryTextButton").data("kendoButton");
button.bind("click", function(e) {
var test = $("#dropdown").val()
$.ajax({
url: "../DesignationProgramTemplate/getTemplate.php",
type: "post",
data: {'id':test,'progid':array},
success: function () {
// you will get response from your php page (what you echo or print)
alert('success'); //coding alert
//refresh
//location.reload("http://hq-global.winx.ehors.com:9280/ehors/HumanResource/EmployeeManagement/DesignationProgramTemplate/template.php");
},
/* error: function(jqXHR, textStatus, errorThrown) {
console.log(textStatus, errorThrown);
}*/
});
});
Any thoughts on the above code?