When comparing Li3 vs FuelPHP, the Slant community recommends Li3 for most people. In the question“What are the best PHP frameworks?” Li3 is ranked 10th while FuelPHP is ranked 15th. The most important reason people chose Li3 is:
Lithium has unified the relational and non-relational database APIs into a single one. Being one of the few frameworks to do it.
Specs
Ranked in these QuestionsQuestion Ranking
Pros
Pro Unified relational and non-relational database API
Lithium has unified the relational and non-relational database APIs into a single one. Being one of the few frameworks to do it.
Pro Robust plugin architecture
Lithium makes use of PHP namespaces to create a powerful plugin architecture. Almost every component of the framework is replaceable.
Pro Fast Bootstrap & Autoloader
This framework loads faster than most due to its class autoloader. It is flexible as well and handles older classes - but requires the developer to define transforms here for naming convention, includes, etc. Many other frameworks use Composer for autoloading and that significantly slows down their bootstrap time because Composer's autoloader is extremely compatible without much developer interaction (it does not require as much involvement for autoloading legacy libraries). So it's a trade-off, speed vs. a little bit of up-front work.
Pro Integrated unit testing
Lithium comes with integrated unit testing. It also has a test dashboard.
Pro Aspect inspired filter system
Lithium's filter system is based on the paradigm of Aspect-oriented programming which aims to increase modularity by separating cross-cutting concerns and helping speed up development.
Pro Great for building an API
Lithium can return JSON and many other formats from the same actions that render templates increasing productivity in many cases. It handles a "type" key in the route which allows it to render various responses with different Content-Types. This is incredibly useful and easy to extend. This combined with closures in routes makes Lithium a very good framework for building a RESTful API.
Pro Total flexibility
Fuel has very few restrictions on how to write code. Classes and controllers can be in any file structure, any folder can be the "modules" folder and native classes can be extended any way you want.
Pro License
FuelPHP is open source and is released under the MIT license.
Pro Out of the box HMVC structure
FuelPHP follows the HMVC pattern which makes it possible to divide the code into smaller modules.
Pro Secure
Fuel takes security very serious, and as a result, has implemented the following measures to ensure the safety of your web applications:
- Output encoding in views
- CSRF protection
- XSS filtering
- Input filtering
- SQL injection
Pro Powerful yet lightweight ORM
FuelPHP is all about being lightweight and simple, this is also demonstrated by it's built-in ORM, it's simple yet powerful. It maps a model to each table in the database, assigns fields on the table depending on the model configuration.
Cons
Con Less than ideal documentation
Documentation is scattered so it takes a little while to learn and figure some things out.
Con Small community
FuelPHP has a pretty small community compared to other alternatives. This means that there are not many resources and guides for it out there, but on the other hand, it's easier to get help from the core team of developers that are working on Fuel.