/** * A patient which is search his information is fetched by this method */ public function getpatientAction() { $id = $this->_request->getParam('id', 0); $pat_obj = new Application_Model_Patient(); $patient = $pat_obj->getById($id); header('Content-type: application/json'); echo json_encode($patient); die; }