Welcome Guest, Not a member yet? Register   Sign In
Just what is a "Model" supposed to be in CI?
#8

[eluser]Chrisbloom7[/eluser]
Coming back to this a bit late...

@überfuzz - Your response was incredibly unhelpful. I'm well aware of the differences between OO versus procedural programming. (As I said, I've been doing this for over 7 years.) I've done plenty of projects where it was fine to just do a quick database query and work on a results array and be done with it, but I've had to fix an equal number of projects where lazy procedural programming led to errors and redundancy that OO would have prevented. In this case, I was asking specifically about OOP because it's what I needed.

@Yorick Peterse - Thanks for that example. I too tried to extend/overload the base Model class, in my case by using ADOdb's Active Record library, but because of the way the CI base self-references itself I kept running into an obscure PHP error having to do with the magic __get function. (see http://bugs.php.net/bug.php?id=38146). Ultimately I just had to give up on CI and move on.

@sl3dg3hamm3r - That has been my experience as well.

In all honestly, although CI has a number of useful libraries, it also has A LOT of useless cruft and shortcomings. I can think of no reason to recommend CI over building a simple MVC/ORM framework from scratch with only what you need, except perhaps if someone wasn't comfortable with OOP on their own and just needed a clean base to start with.


Messages In This Thread
Just what is a "Model" supposed to be in CI? - by El Forum - 05-01-2009, 03:02 PM
Just what is a "Model" supposed to be in CI? - by El Forum - 05-03-2009, 05:22 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 05-03-2009, 07:11 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 05-03-2009, 07:17 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 08-19-2009, 07:53 PM
Just what is a "Model" supposed to be in CI? - by El Forum - 08-20-2009, 05:47 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 08-20-2009, 06:25 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 07:42 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 07:46 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 07:53 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 09:12 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 09:45 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 09:56 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 10:07 AM
Just what is a "Model" supposed to be in CI? - by El Forum - 09-29-2009, 11:55 AM



Theme © iAndrew 2016 - Forum software by © MyBB