Skip to content

Instantly share code, notes, and snippets.

@skoskie
Created January 2, 2013 14:56
Show Gist options
  • Save skoskie/4435092 to your computer and use it in GitHub Desktop.
Save skoskie/4435092 to your computer and use it in GitHub Desktop.
Very simple regex to check if a url is of a particular domain. Doesn't support subdomains except for "www".
^(http(s?):\/\/(www\.?)amazon.com)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment