Does anyone have a link or information on how to handle lists of checkboxes in rails?
I am working on a property site and each property has a list of features which are rendered as
a list of checkboxes. I am trying to figure out how to handle which ones are checked and which not
The check_box helper in your view and a call to update_attributes in
your controller are all you need
Could you please give me the example of using the checkbox helper?
I need to show a list of tags so that tags belonging to the page are checked. I'm bewildered with "method" parameter — it should be a string and I don't know how to write it if I want to call @page.includes?(topic).
hi damian
i recently did a similar thing, so here's maybe what you are looking
for - it may not be the best or most elegant way - i didn't use
checkbox helper, because i couldn't get it going properly - i'm still
a newbie, but this works
Thank you very much!
This is an approach I'm using now, I just wanted to see whether I can write less code. I'm thinking of writing my own helper for it, but as I'm a newbie, I should find out how to do it.