urllib2.splitport()

urllib2.splitport(host)[source]

splitport(‘host:port’) –> ‘host’, ‘port’.