Files
2021-09-01 09:55:27 +08:00

27 lines
574 B
PHP

<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Base
{
public $ifcache = true;
public function __get($property_name)
{
$func = 'get_'.$property_name;
if ($this->$property_name){
return $this->$property_name;
} elseif(method_exists($this, $func))
{
return $this->$property_name = $this->$func();
} else {
return $this->$property_name = false;
}
}
public function get_ci()
{
$ci = &get_instance();
return $ci;
}
}