Hi,
I'm trying to fill up a select box from an Object of my controller.
Here the code of my controller:
function add()
{
$this->customers =& $this->Customers->find('all');
...
...
}
And here the code of my template
<%= select_tag customer_name,null,{customers} %>
Is this the right way? Or how I get it working?
greets
I realized it in the template like this
<select id="customer" name="customer">
{loop customers}
<option value="{customer.id}">{customer.name} {customer.firstname}</option>
{end}
</select>
1 to 2 of 2