Skip to content

Instantly share code, notes, and snippets.

@mojopon
Created January 15, 2013 06:52
Show Gist options
  • Save mojopon/4536739 to your computer and use it in GitHub Desktop.
Save mojopon/4536739 to your computer and use it in GitHub Desktop.
validates_format_of :website, :with => URI::regexp(%w(http https)),
:allow_blank => true,
:message => I18n.t('errors.messages.invalid_url')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment