def postChunked(host, selector, fields, files):
 params = urllib.urlencode(fields)
 url = ('http://%s%s?%s' % (host, selector, params))
 u = urllib2.urlopen(url, files)
 result = u.read()
 [fp.close() for (key, fp) in files]
 return result

def postChunked ( host , selector , fields , files ) : params = urllib . urlencode ( fields ) url = ( 'http://%s%s?%s' % ( host , selector , params ) ) u = urllib2 . urlopen ( url , files ) result = u . read ( ) [ fp . close ( ) for ( key , fp ) in files ] return result
attempt to replace postmultipart() with nearly-identical interface .