I’m trying to display rss feed using jQuery plugin jFeed as below. It’s printing alert(‘ok’) but it’s not displaying feed title alert(feed.title);
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<script type="text/javascript" src="javascript/jquery.js"></script>
<script type="text/javascript" src="javascript/jquery.jfeed.js"></script>
<script type="text/javascript">
$(document).ready(function(){
alert('ok');
$.getFeed({
url: 'http://feeds.nytimes.com/nyt/rss/Technology',
success: function(feed) {
alert(feed.title);
}
});
});
</script>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<div id="main">
</div>
</body>
</html>
You can not load external feeds (from different domains than the calling page).
Quote from the plugin page
There is a proxy.php file in the bundle.
Use it.
To use the provided proxy you need to do
(adjust the path to the proxy file accordingly)