CodeIgniter Forums
Codeigniter compared to Zend Framework 2 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: Codeigniter compared to Zend Framework 2 (/showthread.php?tid=58021)

Pages: 1 2


Codeigniter compared to Zend Framework 2 - El Forum - 05-06-2013

[eluser]php_princess[/eluser]
Hi there. I'd like to hear what the CI community thinks of ZF2.

All I've ever used is CodeIgniter and while I love how simple it is to use, I wonder if another framework might be better suited to my needs. I've thought about trying ZF2, but I'd like to look before I leap. What do you guys feel are ZF2's pros and cons, in comparison to the pros and cons of CI?

Thanks in advance! Smile (And yes I Googled this. I didn't find much. I'd like more opinions.)


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]Harold Villacorte[/eluser]
I am currently working on ZF2 project with the Doctrine 2 module which basically requires Composer. Getting it deployed on shared hosting is darned near impossible. And it is not just a Php 5.3 issue but the php settings have to be right for Composer to work. So yeah ZF2 is fine but the server requirements increase dramatically.


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]php_princess[/eluser]
Good to know. Thanks for the heads up.

Edit: My host lets me access and change the php.ini file. Is that enough?


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]Harold Villacorte[/eluser]
Yeah I can do that too with shell access even but for some settings I get a permission denied error, it depends on the setup. A modern cloud host is my solution of choice. I tried a few of them and found Fort Rabbit. It is a php developer's dream. You can deploy and synchronize with git and just add simple tag to the commit message to run the Composer updates. And it will probably only take one session to learn their system and they are not expensive at all.

But to get back to your original question, this is why we cannot do without Codeigniter. It serves the broadest spectrum of the real world business market which is well behind the nerdy development community. ZF2 seems fine and appears to me to be the leading edge in php frameworks. Everything in between, well, I personally cannot find any reason to bother with it unless I am specifically asked to do so.


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]php_princess[/eluser]
I'm under the impression that ZF2 is good for somebody who wants a framework that lets them apply more OOP concepts. Perhaps I am using CodeIgniter wrong, but I only need a very basic undersatnding of OO PHP to use it. Most of what I learned about OOP, I don't use. Is that my fault or CI's? Is ZF2 better for somebody who wants to improve at OOP?


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]Harold Villacorte[/eluser]
CI is fully object oriented with some procedural code (helpers) included to provide nicer syntax. It is full stack so a lot of what you would be writing in ZF2 is already written in CI. Many things that we take for granted in CI like session handling, form validation, and all the security stuff you would have put together yourself in ZF2 and in doing so you will have to familiarize yourself with stuff you don't normally see in CI code. In addition to the Php 5.3 features you will see features like abstract classes, interfaces, type hinting and stuff like that we normally don't use in CI. To get started with ZF2 all you have to do is clone the skeleton application then run through whatever tutorials you can find then just take your time with it, it's not that hard.


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]php_princess[/eluser]
So ZF2 actually has you writing more code than with CI? Interesting. I thought it would have been the opposite. Granted I'm thinking of ZF1, but I heard that framework gave you everything and the kitchen sink. Is ZF2 even more bare bones than CI? Or am I misunderstanding all of this? lol


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]Harold Villacorte[/eluser]
It is about the same amount of code for a particular task but you have to complete more tasks to get the same result because it is all stand alone classes. The library however is not bare bones, it is actually quite big.


Codeigniter compared to Zend Framework 2 - El Forum - 05-15-2013

[eluser]php_princess[/eluser]
Once you write classes for one project, you can reuse some of them for another, right? So it gets to be less work the more projects you do?


Codeigniter compared to Zend Framework 2 - El Forum - 05-17-2013

[eluser]Harold Villacorte[/eluser]
Yes you would be writing modules in ZF2 like we do in Codeigniter.