I feel that the best practice of PHP is "Array programming"

Source: Internet
Author: User
I also studied PHP for a while and used a bunch of libraries. Then I found that the best practice of PHP is array programming! From the following aspects: 1. basic syntax (such as foreach and array function library): array operations are the easiest, and literal-style arrays (similar to Java Map) are also supported ), <LINKhref = "htt

I also studied PHP for a while and used a bunch of libraries. Then I found that the best practice of PHP is "Array programming!

From the following aspects:

1. basic syntax (such as foreach and array function library): array operations are the easiest, and literal-style arrays (similar to Java Map) are also supported ), you don't have to spend much time on it.

2. Core Engine (Zend Engine): object-oriented programming is cumbersome and not as convenient as Java. More importantly, the PHP engine is inefficient at processing objects.

3. Database access (PHP native): The Returned array has the highest validity rate and is the simplest.

4. Template engine (Smarty, etc.): it is most convenient to create a template when using arrays (you can simply use ).

I personally feel that when I want to build a PHP project in the future, the first step is array-oriented programming, which is fast and efficient ....
 

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.