Skip to content

Instantly share code, notes, and snippets.

@pwlin
Created May 1, 2010 18:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pwlin/386535 to your computer and use it in GitHub Desktop.
Save pwlin/386535 to your computer and use it in GitHub Desktop.
<?php
// google feed api
$url = "http://rss.cnn.com/rss/cnn_topstories.rss";
//$data = file_get_contents("http://ajax.googleapis.com/ajax/services/feed/load?v=1.0&output=json&q=$url");
$data = file_get_contents("http://www.google.com/uds/Gfeeds?num=5&hl=en&output=json&q=$url&v=1.0&nocache=0");
$data = json_decode($data);
var_dump($data);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment