jquery.post() not working
- by Sarang
Hello everyone, I am trying to fetch xml file using jquery.post() method. My code is :
function getTitle()
{
jQuery.ajax({
type: "GET",
url: "https://spreadsheets.google.com/feeds/spreadsheets/private/full.txt",
dataType: "xml",
success: function(xml) {
var i=0;
$(xml).find('entry').each(function(){
if($(this).find('title').text().toString() == "Sample Spreadsheet"){
var href = $(this).find('link')[1].getAttribute('href').toString();
var url="https://spreadsheets.google.com/feeds/worksheets/" + href.split('=')[1] + "/private/full";
alert(href.split('=')[1]);
}
i++;
});
}
});
}
But, it is not giving me alert ! How do I solve ?