if you want choose states depending countries, you have to use the ajax
way. That is when rails renders the page, it doesn't know which country
you will choose. Thus you have to write javascript code to watch the
country field, when it changes, the code sends messages to server and use
You should use 'where' if you are using rails 3. the find_by method is not
suggested now. Hence your problem is easy to be resolved by
User.where(:age=25)
On Wednesday, May 29, 2013 7:52:51 AM UTC+8, Ruby-Forum.com User wrote:
When I use find_by_name method I get LIMIT 1 result.
SELECT
2 matches
Mail list logo