Apply for Zend Framework Certification Training

Zend Framework 1




Step 1 Call list of Data as Explained in previous Tutorials Then create an function
           to retrieve id to delete
public function deleteAction()
{
    	$auth = Zend_Auth::getInstance();
    	if(!$auth->hasIdentity())
    	{
    		$this->_redirect("/index/loginform");
    	}
    	$param= array("host"=>"localhost","username"=>"root","password"=>"","dbname"=>"zend");
    	$db= new Zend_Db_Adapter_Pdo_Mysql($param);
    	$request=$this->getRequest();
    	$this->view->assign('title',$request);
    	$sql="delete from employee where id='".$request->getParam('id')."'";
    	$db->query($sql);
    	$this->_redirect('/index/list');
}
                                    

< Login form in zend framework 1 Zend Framework: Simple Acl Front Controller Plugin >



Ask a question



  • Question:
    {{questionlistdata.blog_question_description}}
    • Answer:
      {{answer.blog_answer_description  }}
    Replay to Question


Back to Top