Welcome Guest, Not a member yet? Register   Sign In
OO newbie
#1

[eluser]ptvw2011[/eluser]
Hi -

I think have been using CI to write procedural code in an MVC file system. I wondered if someone could verify if this is the case.

I have never had the need to set class level variables and setters and getters. I have never instantiated an object

$bar = new Foo($construct);

$stuff = $bar->whatever();

I have made a website which basically consists of links to functions. So if I were to run the above function I would just link it by doing something like http://mydomain/foo/whatever.

It would then interact with the model and do whatever I need to do.

Am I missing something here? I understand OO principles but have really never used them properly in PHP MVC.

Am I writing poor code?

Thanks


#2

[eluser]ptvw2011[/eluser]
Actually I do use classes in this way I just auto load them like $this->order->_getOrderDetail but still I have never used setters and getters!




Theme © iAndrew 2016 - Forum software by © MyBB