I have an php array and I want to insert an element with the index -1 and value “none”.Bassicaly I use this code from cakephp
$customers = $this->Machine->customer->find
(
'list',
array
(
'fields' => array('CUSTOMER_ID', 'CUSTOMER_NAME'),
'order' => 'CUSTOMER_NAME ASC',
'recursive' => -1
)
);
I used the array_push() but it did not work as I wanted