I have been trying
to build the tutorial using Jquery but it does not Work. Ajax using Jquery only works for Local Files not for Remote while WinJS XHR works
$.get('http://theverge.com/rss/index.xml',function(data){
console.log('Data is Here');
});
Is there a workaround for Jquery Ajax to Work.
Edit: I have found the way to parse request data from WinJS XHR. The request data is a
promise Object. You need to pick up the XML Data returned.
However, Jquery Ajax for Cross Domain is still not working for me
var $xml= $(request.xml);
If I use WinJS.xhr to do cross domain Ajax, then i process data using Jquery but that does not work either
function processPosts(request){
var $xml = request.responseXML.selectNodes("//item");
$xml.find("item").each(function() {
var $this = $(this),
item = {
title: $this.find("title").text(),
link: $this.find("link").text(),
description: $this.find("description").text(),
pubDate: $this.find("pubDate").text(),
author: $this.find("author").text()
}
//Do something with item here...
});
}
Kindly, Guide me .....