# http://brospeak.com/ import urllib2 while True: rawinput = raw_input('Translate: ') rawinput = rawinput.replace(' ', '%20') headers = { 'User-Agent' : 'Mozilla/5.0' } req = urllib2.Request('http://brospeak.com/?api=yeah&input='+rawinput, None, headers) html = urllib2.urlopen(req).read() print '----------------------------------' print html print '----------------------------------'