customising ajaxCFC JQuery - BlockUI Messages

By default ajaxCFC includes the JQuery BlockUI plugin to cover the screen and display a message while the ajax request gets processed.

Its default message is "please wait....", so to make it more explanatory we can put a line of code in to help.

Taking our last example of retrieving products, lets turn on blockUI:

$.AjaxCFCHelper.setBlockUI(true);
Now lets add in
blockMessage: "Fetching Products...",

to customise the message users receive.

Here is the complete example:

$.AjaxCFC({
url: "/ajax/ecom.cfc",
method: "getProductList",
data: {"CategoryID":0},
blockMessage: "Fetching Products...",
error: function(r){
   //no action required },
success: function(r) {
   sDumper(r);
}
});

Comments
BlogCFC was created by Raymond Camden. This blog is running version 5.9.001.