[eluser]peterbz[/eluser]
I can't seem to define attributes (variables) inside my Controller
Code:
class UsedCars extends Controller {
private $tabSelected = "usedcars";
function __construct()
{
parent::Controller();
}
function index(){
$common = array();
$common['tabSelected'] = $tabSelected;
$common['view'] = "usedCars";
$data = array();
$data['common'] = $common;
$this->load->vars($data);
$this->load->view("layout");
}
}
When I run this, it prompts me that $tabSelected is not defined.