I have the same problem of this Zend_Db_Table: Delete multiple entries, but the code of fireeyedboy sames to not working. I haven't errors but the db entries still exist. What can i do? My code in the model is identically in effect:
public function deleteUsers($usernames) //elimina più utenti passati con una stringa
{
$where = array();
foreach ($usernames as $username) {
$where[] = $this->getAdapter()->quoteInto('username IN (?)', $username);
}
$this->delete($where);
}
Where $usernames is an array dinamically created by a multicheckbox selection. I assign the parameters to this array in this way in my controller:
$list=$this->getRequest()->getParam('utenti');
$this->_adminModel->deleteUsers($list);
$this->_redirector->gotoSimple('success',
'admin',
null);
For same reason my code go to the successAction but it not do the deleting.