PHP5.0 officially released not fully compatible PHP4 new multiple features

Source: Internet
Author: User
Tags exception handling php language local time mysql new features object model shallow copy
The long-awaited PHP5 was finally officially released July 13 local time. For both the PHP language itself and the PHP user, the PHP5 release is a landmark version. The PHP versions prior to the release of PHP5 have won the favor of many developers with simple syntax, rich library functions, and extremely fast script interpretation, and almost become the preferred web development language on the *nix platform. However, the language itself, PHP syntax, especially OO aspects of the syntax design is not perfect, of course, and the PHP language to the author of the design at the outset.

As we all know, PHP was initially a template system written in Perl, followed by the development of the idea is to facilitate the rapid development of Web applications. A large number of library functions are included, while the development of language models is relatively slow. Although the object-oriented design is added to the PHP4, the language model is imperfect and lacks such basic elements as constructors, destructors, abstract classes (interfaces) and exception handling. This greatly limits the ability to use PHP to complete large-scale applications.

And the birth of PHP5, then fundamentally changed the above disadvantages of PHP. The adoption of Zend II engine, complete object model and improved syntax design. Eventually makes PHP a fully designed, truly object-oriented scripting language. We expect that the advent of PHP5 will bring the entire PHP community a new round of library and application development improvements.

The PHP5.0 version reinforces the following features. First, fully implement object-oriented. In the PHP4 version, an object that is deeply copied as the default is entered, and in PHP5 becomes a shallow copy of the default value. As a result, PHP5 is not fully compatible with PHP4, but provides functionality called PHP compatibility mode. followed by XML functionality, the PHP5.0 version supports an interface for XML processing that visually accesses XML data, called SimpleXML. It also reinforces XML Web service support, and the standard supports SOAP extension modules.

On the database side, the new PHP version offers a new interface--mysqli designed to access MySQL. In addition to the previous interface, you can use the new features of MySQL, such as object-oriented interfaces and preprocessing statements (Prepared Statement). In addition, PHP5.0 is also bundled with small capacity rdbms--sqlite.



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.