PHP tips and tips

Source: Internet
Author: User
1. When you are looking for information about a specific PHP function, go to http://php.net /. For example, http://php.net/join. This will direct you to the correct location in the online manual on a server near your geographic location.

2. Try this: pear install apc. The pear command is a useful installation program. It can even be used to install PHP extensions written in C. In this case, it will install the APC opcode high-speed cache extension.

3. Use opcode cache to improve performance. See #2.

4. There is no error in mixing OOP and process code in PHP. When the object is meaningful, use the object, and switch to other situations.

5. It is easier to expand PHP with your customized C or C extension than you think. See README. EXT_SKEL in the PHP source code version.

6. echo <EOB syntax is very useful for outputting text blocks with the complete $ variable replacement, and there is no need to avoid anything. EOB;
7. PATH_INFO is great! Use it to clear ugly URLs.

8. Use a record program, pear install apd.

9. Database abstraction is mostly a fictitious story. There is nothing wrong with direct database calls. It uses all the skills and tips that must be provided by the database you select to achieve the highest possible performance.

10. Keep using your basic technologies and build simple blocks. Use wireless Web servers to avoid complicated frameworks and abstraction layers, giving you the opportunity to track and debug any problems that may occur. It is easy to solve the Web problem; do not try to make it difficult.


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.