New Features of PHP 6

Source: Internet
Author: User
Tags pear representational state transfer soap client

The next PHP version, V6, contains many new features and improved methods, making it easier to use in aspect of image targeting.
Other important features: for example, Unicode support in core function data, which means PHP 6 provides better and more reliable support for the country.

PHP is already popular,
It is used by countless websites and supported by most of the Internet access providers. It is used by large Internet companies like Yahoo. In the upcoming PHP version of phpwind, some new features are successfully added to allow PHP
It is easier to use and safer in combination. Are you ready to accept PHP 6? If you upgrade your program tomorrow, will your program work well? What should you do? This article integrates PHP
6. Some of them are transplanted to the PHP v5.x version. Your current Script may need to be optimized.

If you are not using PHP now, but are still taking test of it, test its new features. These features, From Unicode core support to XML support, make it easier to fill in the PHP application for your feature.

New Features of PHP 6If you want to publish this article please indicate the location, Seven's blog, Email: See7di@Gmail.com
PHP 6 is already used as a producer snapshot, so you can use this article to list many features in the next article, these features are already available in the current snapshots. Information source.

ProgressUnicodeSupportIf you want to publish this article please indicate the location, Seven's blog, Email: See7di@Gmail.com
Many of the core functions of PHPUnicodeThe upgrade of String Support will produce a significant impact on these new features because it allows PHP to provide more support for Chinese character. Therefore, if a developer or framework uses different statements, such as Java program statement, because it has over-PHP state-based support, when supporting the transformation, he will take a moment to test PHP.

Because today you can download PHP V6 of the developer version, you will see that some function functions support Unicode strings. There is a function that has been processed and verified to handle Unicode and access the source.

NamespaceIf you want to publish this article please indicate the location, Seven's blog, Email: See7di@Gmail.com
Naming spaces are a way to avoid the abrupt naming of function numbers or classes, so that your function numbers and classes and methods cannot be retrieved, instead of using the method named example in the previous example. Therefore, you can name a class name that someone else may already use without worrying about how to generate an issue during the migration. Table 1 provides an example using the namespace in PHP.

You do not need to update or change the content in the source program because any PHP program you use does not contain the name space, and it works very well. Because the naming space feature seems to be ported to PHP 5.3 X, if it can be used, you can reference the naming space in your program.

Table 1: Examples of namespacesIf you want to publish this article please indicate the location, Seven's blog, Email: See7di@Gmail.com
<? Php
// I'm not sure why I wocould implement my own XMLWriter, but at least
// The name of this one won't collide with the one built in to PHP
Namespace NathanAGood;
Class XMLWriter
{
// Implementation here...
}

$ Writer = new NathanAGood: XMLWriter ();

?>
Web 2.0 features
Depending on how you use PHP and what scripts you are currently using, the current statement and method are poor, some of the following features may or may not affect to the greatest extent. This refers to those Web 2.0 features that directly allow you to reference to your PHP application.

SOAP
SOAP is a Web server ."
And many other languages, such as Java and micro-channel. NET. Although there are other ways to activate and use web services, such
Table-based relational transformation (Representational State Transfer)
) REST, SOAP is still the most common in making different platforms operable. In addition, SOAP is used in PHP connector and PEAR connector, which is not supported in PHP connector, because
You can use this token or call your ISP to use it. In addition, the PEAR package allows you to create a SOAP client and server, such as a SOAP package.

If you change the configuration, SOAP will be used in PHP 6. This feature will easily provide you with SOAP client and SOAP server, allowing you to provide your own application or web server.

If the SOAP connector is set by parameter, it means you cannot set it in PHP, if your PHP application is developed and released to an ISP Server, you may need to check your ISP, certificate SOAP and use it for their upgrade.

XMLIf you want to publish this article please indicate the location, Seven's blog, Email: See7di@Gmail.com
In PHP 5.1, XMLReader and XMLWriter have become part of the PHP core, which enables you to work more easily if you need to use XML in your PHP program. Similar to SOAP injection, if you use SOAP or XML, this is good news because PHP 6 is more compatible with you than PHP 4, which has already been released.

Deleted things
Division
Some new features are available. The PHP 6 engine will remove some existing features in the previous version. Most of these functions, such as register_globals and safe_mode
It is regarded as "broken" in current PHP 」. Because they may expose some security vulnerabilities. In the effort to clean up PHP, these will be removed or removed from PHP in the next version. Opponents think that most
ISP or enterprise will retain the current Script because upgrading to PHP6 will break the current Script, however, the support team thinks it is highly recommend that PHP administrators fix these vulnerabilities and provide
Provides a secure and reliable migration tool.

Functions to be removed from PHP include:
Magic_quotes register_globals register_long_arrays safe_mode

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.