How to call controller function from view in codeigniter?

后端 未结 4 1510
陌清茗
陌清茗 2021-01-16 20:17

With codeigniter, I have a controller as in the following:



        
4条回答
  •  爱一瞬间的悲伤
    2021-01-16 20:37

    I think you forgot to load URL helper

    function test()
    {
    
        $this->load->helper('url');
        $data['message']= $this->input->post('message');
        $this->load->view('backend/test',$data);
    
    }
    

    this might help you

提交回复
热议问题