Commit ec911cb8 authored by Seth Meranda's avatar Seth Meranda
Browse files

Since we're on a PHP server, use PHP to parse and output the JSON feed instead of JS.

parent 40ad2098
......@@ -171,8 +171,17 @@
<div class="grid4" id="newsItems">
<script src="http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20rss%20where%20url%3D'http%3A%2F%2Fpipes.yahoo.com%2Fpipes%2Fpipe.run%3F_id%3D67df958f5c60c5217e7c28fb3b4556ff%26_render%3Drss'&format=json&diagnostics=true&callback=buildNews" type="text/javascript"></script>
</div>
<h3>News from Nebraska</h3>
<ul id="newsList">
<?php
$news = json_decode(file_get_contents("http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20rss%20where%20url%3D'http%3A%2F%2Fpipes.yahoo.com%2Fpipes%2Fpipe.run%3F_id%3D67df958f5c60c5217e7c28fb3b4556ff%26_render%3Drss'&format=json&diagnostics=true"), true);
//print_r($news['query']['results']);
foreach($news['query']['results']['item'] as $result){
echo '<li><a href="'.$result['link'].'">'.$result['title'].'</a></li>';
}
?>
</ul>
</div>
<!-- TemplateEndEditable -->
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment