Hacker Timesnew | past | comments | ask | show | jobs | submitlogin

Having taken over a project that uses CI at it's core, I've found a number of things that definitely put it in a league below frameworks that were built with PHP 5.3 in mind. * Way too much magic - everything (libraries, models, etc.) is globbed onto a superglobal class, which breaks auto-complete in IDEs and in general makes debugging harder * No proper autoloader (PSR-0 style) - the built in autoloader can't autoload anything that doesn't fit into the CI world which tends to lead to unnecessarily large classes (anything that isn't a model gets lumped into a library) * Setting up routes gets messy fast (it's all defined as a single associative array) * No built in template system (which, in my experience, encourages bad behavior in views)


Okay, so a bunch of personal preferences that don't actually matter in the real world? Thanks for your insight, but it does not make CodeIgniter bad.

> frameworks that were built with PHP 5.3 in mind.

Well no crap, CodeIgniter is built for newbies in mind, people who don't have up to date PHP installs because their shared hosting doesn't keep it THAT up to date.

The newest versions of CodeIgniter are VERY good, and just like the haters of PHP, you're just hating on versions of CodeIgniter that are at least 3 versions old. Learn the updated system, then base your claims on that, not something you looked at 2+ years ago.


Those aren't (all) personal preferences. Using superglobals is definitively bad, in the same way that using GOTO is. Not using PSR-0 autoloading is flying in the face of the community consensus and makes it much harder to use other libraries with CI compared to other frameworks.

Your point about PHP versions isn't very valid. 5.3 is over 3 years old now! Plenty of cheap hosts are far more up to date than that.

There is a difference between being "newbie friendly" (which I will admit, CI is - it's a lot easier to get into than say, Zend, by orders of magnitude) and "enabling bad practices". You could say that using mysqli and concatenating data into your queries is newbie friendly, and it is - it's a lot simpler conceptually than prepared statements, but that doesn't stop it being categorically a bad idea.

For the record my CI experience ended about 9 months ago, and I have contributed code to CI, so I feel that when I say certain parts of the internals are very badly coded I do have some valid perspective on that issue.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: