Vorrei aggiungere un particolare...
ho aggiunto una gestione approssimativa degli errori e ho scoperto che la widget non funziona a causa di un errore.
inserendo
ottengo questo messaggio:codice:$(document).ready(function(){ $.ajax({ type: "GET", url: "9001-foxone.xml", dataType: "xml", success: function(xml) { $(xml).find('Event').each(function(){ // reading data from XML var id = $(this).find('EventID').text(); var title = $(this).find('Title').text(); var shortD = $(this).find('ShortDescription').text(); // writing data to widget $('<div class="items" id="event_'+id+'"></div>').html(''+title+'').appendTo('#content_panel'); $('<div class="short"></div>').html(shortD).appendTo('#event_'+id); }); }, error: function(e) { $('<div class="short"></div>').html("Failure: "+e).appendTo('#content_panel'); } }); });
Failure: object xhtmlHttpRequest
Quindi... come mai se eseguo la pagina funziona e se eseguo la widget non funziona? Devo inserire qualcosa nel config.xml per abilitare un certo comportamento?
Grazie

Rispondi quotando