Jeżeli komuś to pomoże to wklejam kod JS do ładowania zawartości, używam frameworka Prototype, ale nie sądze zeby to była jego wina:
Kod
function loadContent( call, params, targetDiv, destination){
if( params == null)
var params = {};
destination ? params['destination'] = destination : params['destination'] = 'service';
params['call'] = call;
new Ajax.Request( window.serverAdress + "main.php", {
method: 'get',
parameters: params,
onSuccess: function( response){
var elementTab = response.responseXML.getElementsByTagName('extra');
for( var i = 0; i < elementTab.length; i++ ){
if(elementTab[i].hasChildNodes()){
$( elementTab[i].getAttribute('target')).innerHTML = elementTab[i].childNodes[0].nodeValue;
console.log("T: ", elementTab[i].childNodes[0].nodeValue);
console.log("T2: ", elementTab[i].getAttribute('target'));
}
}
}
})
};
if( params == null)
var params = {};
destination ? params['destination'] = destination : params['destination'] = 'service';
params['call'] = call;
new Ajax.Request( window.serverAdress + "main.php", {
method: 'get',
parameters: params,
onSuccess: function( response){
var elementTab = response.responseXML.getElementsByTagName('extra');
for( var i = 0; i < elementTab.length; i++ ){
if(elementTab[i].hasChildNodes()){
$( elementTab[i].getAttribute('target')).innerHTML = elementTab[i].childNodes[0].nodeValue;
console.log("T: ", elementTab[i].childNodes[0].nodeValue);
console.log("T2: ", elementTab[i].getAttribute('target'));
}
}
}
})
};