CountryTrash
Member
Hi there,
I have been grappling with this for some hours now and need advise:
I have simplified the ajax function just to ensure that a value gets returned before putting back the real workings.
I have a 7.js file which contains the following function which gets called from the elements "on change" java:
function clear_uif() {
var url = 'http://www.databook.co.za/lptenders/index.php?option=com_fabrik&format=raw&view=plugin&task=userAjax&method=clear_uif';
var invite_id = 4;
new Request({
url: url,
data: {
method: 'clear_uif', 'invite_id':invite_id
},
onComplete:function(r){
form_7.formElements.get('tender_invitees___tender_info_status').update(r);
}
}).send();
};
(if I change the "update(r) to say "update("test") it actually returns test to the element nominated in the function. If I put it back to "update(r)" the field receives "undefined"
The simplified user_ajax function reads:
function clear_uif() {
$answer = "Hello";
echo $answer;
}
I have been grappling with this for some hours now and need advise:
I have simplified the ajax function just to ensure that a value gets returned before putting back the real workings.
I have a 7.js file which contains the following function which gets called from the elements "on change" java:
function clear_uif() {
var url = 'http://www.databook.co.za/lptenders/index.php?option=com_fabrik&format=raw&view=plugin&task=userAjax&method=clear_uif';
var invite_id = 4;
new Request({
url: url,
data: {
method: 'clear_uif', 'invite_id':invite_id
},
onComplete:function(r){
form_7.formElements.get('tender_invitees___tender_info_status').update(r);
}
}).send();
};
(if I change the "update(r) to say "update("test") it actually returns test to the element nominated in the function. If I put it back to "update(r)" the field receives "undefined"
The simplified user_ajax function reads:
function clear_uif() {
$answer = "Hello";
echo $answer;
}