function getTermThis()
{
$rs=$this->db->query("select * from tb_term t inner join tb_year y on t.year_ID=y.year_ID order by t.term_ID desc limit 1");
$row=$rs->row();
$data['term_ID']=$row->term_ID;
$data['term']=$row->term;
$data['year_ID']=$row->year_ID;
$data['years']=$row->years;
return $data;
}
controller
function index()
{
$this->load->model('term_model');
$data['term_data']=$this->Term_model->getTermThis();
$this->load->view('term',$data);
}