dante
5 Oct 2007, 2:38 AM
This is actually are really simple question, however, so far I failed in finding any coherent examples of how to make simple ajax requests using ext. I am using symfony which again uses prototype to perform ajax requests and I would like to switch to ext completely. So what I need is an example how to write the following prototype code in ext:
new Ajax.Updater(
'DIV',
'URL',
{
asynchronous:true,
evalScripts:true,
onLoading:
function (request, json) {
Ext.get('DIV').getUpdateManager().showLoading();
},
onComplete:
function (request, json) {
jQuery('#DIV').hide();
jQuery('#DIV').slideDown('normal');
}
}
);
As you can see, I just need to pass a DIV (a div id) to be updated and URL (target url of the reuqest).
So what's the corresponding code in ext? Thanks a lot.
new Ajax.Updater(
'DIV',
'URL',
{
asynchronous:true,
evalScripts:true,
onLoading:
function (request, json) {
Ext.get('DIV').getUpdateManager().showLoading();
},
onComplete:
function (request, json) {
jQuery('#DIV').hide();
jQuery('#DIV').slideDown('normal');
}
}
);
As you can see, I just need to pass a DIV (a div id) to be updated and URL (target url of the reuqest).
So what's the corresponding code in ext? Thanks a lot.