[Rails] Where to start?
rails at agilemethods.net
rails at agilemethods.net
Wed Dec 14 18:43:13 GMT 2005
On 12/13/05, Igor Zaretsky <izaret at yahoo.com> wrote:
>
> I am currently reading "Programming Ruby" book.
Awesome book!
> One thing definetely screws up my sweet dreams: how to do validation?
> I know "if" and "else", but
> where to put them?
> in which folder?
> how to pop up or display message?
Agile Web Development explains all of this. Definitely get it!
In short validation/popup goes in the model like this:
validates_format_of :image_url,
:with => %r{^http:.+\.(gif|jpg|jpeg|png)$}i,
:message => "mist be a URL for a GIF, JPG,
JPEG, or PNG image"
> Is the book I am reading is the proper book for me at this time?
> What would you suggest me to read?
More information about the Rails
mailing list