import httplib
try:
import json
except ImportError:
import simplejson as json
path = ('/maps/geo?q=207+N.+Defiance+St%2C+Archbold%2C+OH''&output=json&oe=utf8')
connection = httplib.HTTPConnection('maps.google.com')
connection.request('GET', path)
rawreply = connection.getresponse().read()
reply = json.loads(rawreply)
print(reply)
在执行它时,我没有得到想要的输出,而是得到:
{u'Status': {u'code': 610, u'request': u'geocode'}}
如果有人知道解决方案,请帮助我。