开发者

add iframe while calling controller to view in codeigniter

开发者 https://www.devze.com 2023-03-28 22:51 出处:网络
call controller to view i use this code.. i want to add \"template/home/home\" page in to iframe tag while calling controller to view.

call controller to view i use this code.. i want to add "template/home/home" page in to iframe tag while calling controller to view. how can i do?

class main_con extends Controller
{
    function main_con()
    {
        parent::Controller();
//        $this->freakauth_light->check('user');
        $this->_container = $this->config->item('FAL_template_dir') . 'template/container';

        $this->开发者_Python百科load->library('FAL_front', 'fal_front');
    }   
    function index()
    {
        $data['redirect_page'] = 'template/home/home';
        $this->load->vars($data);
        $this->load->view($this->_container);
    }
}

thank you in advance...


I'm not quite sure if I understand your problem but:

The iframe is in your view template right? So what you need to do is just print the content of your variable in the src attrib of the iframe.

0

精彩评论

暂无评论...
验证码 换一张
取 消