• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to included a file with in controller

#3
[eluser]TheFuzzy0ne[/eluser]
You could pass the data array in to the view loader:
Code:
$this->load->view('contentleft', $data);

...or you can load the $data array into the view scope with $this->load->vars().
Code:
$data['login'] = $this->excute->loginname($username);
$this->load->vars($data);
$this->load->view('header');
$this->load->view('contentleft');
$this->load->view('home');
$this->load->view('footer');

The latter being the most efficient method to use.


Messages In This Thread
how to included a file with in controller - by El Forum - 07-06-2009, 07:02 AM
how to included a file with in controller - by El Forum - 07-06-2009, 08:52 AM
how to included a file with in controller - by El Forum - 07-06-2009, 08:56 AM
how to included a file with in controller - by El Forum - 07-06-2009, 11:26 PM
how to included a file with in controller - by El Forum - 07-07-2009, 03:50 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.