[eluser]CocoMansur[/eluser]
I tried that already but it doesn't work.
when i load my default page it displays, undefined variable get_latest.
here is the code with the construct
Code:
class Base extends CI_Controller{
public function __construct(){
parent:: __construct();
$this->do_this();
}
public function do_this(){
$data['get_latest'] = $this->log_templates->get_latest_log(); // gets the latest log
}
public function welcome(){
(other codes here...)
$this->load->view('template',$data);
}
public function marketting(){
$data['get_latest'] = $this->log_templates->get_latest_log();
(other codes here...)
$this->load->view('template',$data);
}
public function documentation(){
$data['get_latest'] = $this->log_templates->get_latest_log();
(other codes here...)
$this->load->view('template',$data);
}
}