Forum: Ruby on Rails howto display multiple symbol values in collection_select()

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
7a1d3c7a520355e32375a272b237036f?d=identicon&s=25 Skeets (Guest)
on 2007-01-19 16:30
(Received via mailing list)
i have the following code:


@vehicles = Vehicle.find(:all, :order => "license")


<%= collection_select(:mileage, :vehicle_id, @vehicles, :id, :license)

what i want:

instead of just license, i want:

:make + " " + :model + ", " + :license in place of just :license.

obviously, this doesn't work.  nor does putting an instance variable in
place of :license.

any help would be appreciated.
This topic is locked and can not be replied to.