Skip to content

Instantly share code, notes, and snippets.

@halos
Created October 24, 2012 11:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save halos/3945561 to your computer and use it in GitHub Desktop.
Save halos/3945561 to your computer and use it in GitHub Desktop.
Code to get a domain from an URL
dom = url.split('//')[-1]
dom = dom.split('/')[0]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment