Problem using JQuery XML and PHP
So i have an HTML page which contains this script:
<script type="text/javascript">
$(document).ready(function(){
$.ajax({
type: "GET",
url: "http://meteo.uniparthenope.it/prods/timeseries._dev.php?region=ca001&when=now",
dataType: "xml",
success: function(xml) {
$(xml).find("time").each(function()
{
$("#output").append($(this).attr("date") + "<br />");
});
}
});
});
</script>
This script doesn't work! If i copy the content given by the url in an XML File, the script works.
Am I doing right?
The html file isn't on the same machine of the php page.
I validated the response given by the url above through the wc3 online tools.
Using firebug to debug the script, i can read that the response is empty.
I don't know other details to give.