Home > Backend Development > PHP Tutorial > A brief comment on the shortcomings of developing large-scale systems with PHP (1)_PHP Tutorial

A brief comment on the shortcomings of developing large-scale systems with PHP (1)_PHP Tutorial

WBOY
Release: 2016-07-15 13:25:59
Original
894 people have browsed it

The author has been committed to the development of PHP applications for the past four years. PHP is really easy to write. But PHP also has some very serious flaws.

The author below will give my own reasons why PHP is not suitable for websites larger than small amateur websites.

1. Poor support for recursion

Recursion is a mechanism by which a function calls itself. This is a powerful feature that can turn something complex into something very simple. An example of using recursion is quicksort. Unfortunately, PHP is not very good at recursion. Zeev, a PHP developer, said: "PHP 4.0 (Zend) uses a stack approach for dense data rather than a heap approach. This means that the number of recursive functions it can tolerate is significantly less limited than other languages." See bug 1901. This is a very bad excuse. Every programming language should provide good recursion support.

2. Many PHP modules are not thread-safe

A few years ago, Apache released version 2.0 of the web server. This version supports multi-threading mode, in which one part of the software can run multiple parts at the same time. The inventor of PHP says that the core of PHP is thread-safe, but non-core modules may not be. But nine times out of ten, you want to use this module in a PHP script, but this makes your script incompatible with Apache's multi-threaded mode. This is why the PHP team does not recommend running PHP in Apache 2's multi-threaded mode. PHP's poor multi-threaded mode support is often cited as one of the reasons why Apache 2 remains unpopular.

Please read this discussion:

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/446653.htmlTechArticleThe author has been committed to the development of PHP applications in the past four years. PHP is really easy to write. But PHP also has some very serious flaws. The author will give his own reasons below, why...
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template