User:-JSON example-

From XPUB & Lens-Based wiki
Revision as of 11:23, 27 September 2013 by Luisa Moura (talk | contribs) (Created page with "import turtle import urllib2 import json url = "http://gdata.youtube.com/feeds/api/standardfeeds/top_rated?v=2&alt=jsonc" f = urllib2.urlopen(url) data = json.load(...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

import turtle

import urllib2

import json


url = "http://gdata.youtube.com/feeds/api/standardfeeds/top_rated?v=2&alt=jsonc"


f = urllib2.urlopen(url)


data = json.load(f)

things = data['data']['items']

for i in things:

print i['category']