New users are new to PHP. which framework is easier to use?

Source: Internet
Author: User
I have been familiar with php for a short time, but I want to understand the PHP framework and the idea of MVC. I have never been familiar with such a framework before. I would like to ask if you have any good frameworks to recommend, what is the starting point. Especially for newcomers ~ I have been familiar with php for a short time, but I want to understand the PHP framework and the idea of MVC. I have never been familiar with such a framework before. I would like to ask if you have any good frameworks to recommend, what is the starting point. Especially for newcomers ~ Reply: I used to read the English Framework. I also read a lot of discussions on StackOverflow and Quora. In fact, the Framework is a habit. Another point is to select a framework that is frequently maintained. If you have learned some unpopular frameworks and people do not maintain them, it is a waste of resources.
To sum up some frameworks I have used:
  1. CodeIgniter: I used version 1.7. the code efficiency is average because it is compatible with PHP 4. After 2.0, PHP 4 was abandoned and the code was cleaner. The official documentation is very detailed, and the community is very large. There are many users. The disadvantage is that there is no good ORM library. the default Model is based on ActiveRecord, but it is actually an extension of SQL.
  2. Zend: the so-called official PHP framework has a loose architecture and can be used as needed. At the beginning, it was not very good at learning, but if you really understand it, it would be very efficient. Because Zend is behind the scenes, it will not worry about the problem of non-maintenance. The disadvantage is that although the document looks a lot, it is not easy to understand.
  3. Symfony: it should be a veteran Framework of French, which is very large and suitable for enterprise-level projects. Many configurations use YAML, and the environment requirements are very troublesome. I gave up simply looking at it.
  4. Yii: it should have been developed by Chinese people. I used it before when I was developing it with my friends. The Performance is very good, but the Coding Style in it is not very fond of it, and the documentation is also good.
  5. Kohana: I used to be CI-based, but later I rewritten the code, but inherited the CI philosophy. The HMVC architecture is not easy to learn, but the code is very clean and efficient. The built-in ORM is also good, but the disadvantage is that the documentation is not comprehensive.
  6. Edit 1:I almost forgot about CakePHP: this is the first framework I have come into contact with. it is also the most like Ruby on Rails. Bake script can automatically generate many things, but I do not like automatic generation very much. The running speed is slow, probably because there are too many overheads. Support for PHP 4, but later several core members created a PHP 5.3 framework called Lithium (http://lithify.me/) Native support for MongoDB. I only read the documentation and it is useless.

The above are common frameworks and Comprehensive. The following are some of the lightweight ones:
  1. Slim Framework: my personal favorite lightweight Framework. it is organized based on RESTful route and the compressed package is only 80 KB. I have inherited the philosophy of Sinatra and Web. py. I have discussed it with the author before. he changed from Singleton to Instance in 1.5, but I don't think it is necessary. I like Version 1.3 very much. This is not a full stack MVC framework and does not require OO.
  2. LightVC: this is a lightweight (compressed package of 24 K). it only provides VC and does not provide Model. at the same time, I thanked a ORM called CoughPHP for its good combination.
  3. Flourish Lib: this is not a framework, but a collection of libraries, many of which are useful.

Finally, we recommend another ORM, which is usually popular with Doctrine and Propel. My favorite is RedBean. Currently, all developers use Slim for Route, copy some code from Flourish, and use RedBean for ORM. although it looks like a detour, I am used to it now, and I am familiar with it. We strongly recommend that you do not use the framework for beginners!
What is the relationship between yii and CI ?? I recommend CI-codeignighter.

Below are several reasons:
  1. A mature development community has a group of people learning this framework with you. if you don't understand it, you can ask, there is a Chinese community in China (Http://codeigniter.org.cn/).
  2. Compared with zendframk, zendframk has a relatively simple syntax, and has some supporting books for reference. although it is old, it still has reference value.
  3. For detailed help documents, the official ci blog has UserGuide, which helps you quickly understand related syntaxes and functions. it is very detailed, and the ci framework itself has made a lot of comments.
Conclusion: ci is a very good framework for beginners and is easy to use.

Note: reference book list
CodeIgniter for Rapid PHP Application Development
Http://book.douban.com/subject/3065901/ If you are new to PHP, I suggest not to touch the framework first. There are a lot of refined content in the framework, which is easy to know, but it is difficult to know why, and is not conducive to basic training.

MVC is a programming idea, and framework has little to do with, you can be very familiar with MVC but not familiar with the framework, you can also be very familiar with the framework and not familiar with mvc php without like http://ASP.NET Such MVC architecture, like CI, implements MVC through router. I suggest you start with basic learning and then use the framework. When you use the CI, Zend, and other PHP frameworks, you will find that they are basically the same, so you know them better. In China, thinkphp or CI documents are not recommended in English.
For better English, we recommend that you select the basic PHP language first, and then consider CI, SpeedPHP, and ThinkPHP. the following two Chinese documents are quite complete. It is recommended that you master PHP before learning and considering the framework.
PHP framework. My team is using CI

ThinkPHP and CI are both good, and there are also many Chinese learning documents.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.