You probably already know that you can use options_from_collection_for_select helper method generate <option></option> from a collection. If you are unaware of it, you can check this api documentation. It helped me greatly until I needed some custom attributes to each <option></option> which will be used by jQuery for doing some tasks in UI level. Custom attributes will […]
↧