[eluser]solid9[/eluser]
Hi guys
I have encountered an error below,
Quote:Severity: Notice
Message: Undefined property: Researchers::$researchers
Filename: controllers/researchers.php
Line Number: 32
controller,
Code:
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Researchers extends CI_Controller {
public function index()
{
$this->load->model('researchers');
$this->load->view('researchers');
}
function ahe_page()
{
$this->load->view('ahe_page');
}
function add_researcher()
{
$this->load->helper('date');
$data = array(
'prod_name' => $this->input->post('prod_name'),
'phase' => $this->input->post('phase'),
'description' => $this->input->post('description'),
'main_url' => $this->input->post('main_url'),
'donation_url' => $this->input->post('donation_url'),
'last_update' => now(),
'updated_by' => '',
);
$this->researchers->add_record($data);
}
/*
function show_researchers()
{
$data['query'] = $this->researchers->show_record();
$this->load->view('researchers', $data);
}
*/
}
I hope someone will help me.
Thanks in advanced.