public function convertlinksAction() { $this->_helper->layout->disableLayout(); $this->_helper->viewRenderer->setNoRender(true); $fliModel = new Default_Model_FileLinks(); if (!$fliModel->convertDone()) { $fliModel->convert(); echo "converting.."; } else { echo "convert already done"; } }
/** * * delete single file from single content, check if the file is still needed * @param $id file id * @param $id_target * @param $type */ public function deleteFile($id, $id_target, $type) { $fliModel = new Default_Model_FileLinks(); $results = array(); if (!$fliModel->removeLink($id, $id_target, $type)) { array_push($results, $this->deleteFromFilesystem($id['id_file'])); $where = $this->_db->quoteInto('id_fil = ?', $id['id_file']); array_push($results, $this->delete($where)); } return !in_array(false, $results); }