lundi 18 mai 2015

Ruby on rails validates with code not working

is there a mistake here? I want the entry to start with http://amzn.com/w/ followed by anything. But what ever i enter i get the error message.

validates :wl_url, format: { with: /\A(http:\/\/amzn\.com\/w\/)+([a-z0-9]*)\z/, 
  message: 'Please make sure the Wish List code starts with http://amzn.com/w/, if unsure see "how it works" page for instructions.'}

Aucun commentaire:

Enregistrer un commentaire