Send a request to the server.
Optional
url: null | stringThe location of the file on the server.
Optional
settings: IxAjaxSettingsAjax settings e.g. {dataType: 'json', urlParameters: {}}
Request a groovy file, stored in the current application.
Path to a groovy file started after application/${application.guid}/groovy/
.
Ajax settings e.g. {dataType: 'json', urlParameters: {}}
.
Optional
appContext: UpObject | HTMLElementElement object represents an HTML element.
ix.ajax().requestAppGroovy('newGuid.groovy', {
dataType: "json",
data: {
"hello": "world!"
},
success: function (data) {
Notifier.status.notify(data.guids.join("<br>"));
}
}, ix.util.getHtml("<GUID>"));
Request a groovy file.
Path to a groovy file (should be in the portal groovy directory: <portal>/groovy
).
Ajax settings e.g. {dataType: 'json', urlParameters: {}}
.
ix.ajax().requestGroovy('groovy/de/uplanet/lucy/samples/newGuid.groovy', {
dataType: "json",
data: {
"hello": "world!"
},
success: function (data) {
Notifier.status.notify(data.guids.join("<br>"));
}
});
Add the current application page context informations (Request-Params e.g. rq_AppGuid
and form fields) to the current ix.Ajax
object.
Element object represents an HTML element.
var ixAjax = ix.ajax();
ixAjax.setAppContext(ix.util.getHtml("<GUID>"));
ixAjax.requestGroovy('groovy/de/uplanet/lucy/samples/newGuid.groovy', {
data: {
"hello": "world!"
},
success: function (data) {
Notifier.status.notify(data.guids.join("<br>"));
}
});
Helper Class to perform specific asynchronous HTTP (Ajax) request.
IMPORTANT
Please use static ajax instead of
new ix.Ajax()
for better update support!