Pages

Tuesday, January 10, 2012

Convert Joomla 1.5 AJAX into Joomla 1.7



Joomla 1.5 AJAX Syntax

var a = new Ajax( url, {
 method: 'get',onComplete: function(){
 alert("AJAX is Working in Joomla 1.5")},
 update: element
}).request();


Joomla 1.6/1.7 AJAX Syntax

var a = new Request.HTML({
 url: url,
 method: 'get',onComplete: function(){
 alert("AJAX is Working in Joomla 1.7")},
 update: element
}).send();


Joomla 1.5 above AJAX syntax is not working in Joomla 1.7 because in Joomla 1.7 AJAX is not defined in mootools. so this perticular Joomla 1.6/1.7 AJAX syntax is properly working in Joomla 1.7 and in Joomla 1.6 also.

No comments:

Post a Comment