PHP 7 Is Here And HostBreak Is Ready!

New PHP 7 has been unveiled and has acquired General Availability Status. This is the most important release in the PHP arena after release of PHP 5 back in July 2004. This will revolutionized all of our web applications which are powering websites, mobiles, enterprises and cloud computing. All new PHP 7 showcases improved performance, massive reduction in memory consumption and many language features for making applications super fast. The last year has seen many tests being published about its performance. PHP 7 uses new Zend Engine 3.0 which will boost apps performance by 2x and 50% better memory consumption than the previous version so you can serve more users without additional hardware. This is now the ultimate choice for web developers.

Release Details

  • 25/08/2015: PHP 7 on Magento EE
  • 27/08/2015: Deprecated functionality which will be removed in PHP 7
  • 01/09/2015: PHP 7.0.0 RC 1
  • 07/09/2015: PHP 7.0.0 RC2 has been released. PHP 7 will be available on the 12th of November.
  • 15/09/2015: PHP 7 and WordPress, Return types, Scalar types, Threading for PHP, PHP7 Reference, php7cc
  • 22/09/2015: Backwards compatibility issues, PHP 7 screencasts, and a new overview
  • 29/09/2015: PHP 7 tutorial
  • 26/10/2015: The Acquisition of Zend and PhpStorm 9
  • 07/11/2015: PHP 7 Hidden Features
  • 24/11/2015: PHP 7 Docker Image for Magento 2
  • 24/11/2015: PHP 7 vs HHVM
  • 01/12/2015: PHP 7 RC 8 has been released
  • 03/12/2015: PHP 7 HAS BEEN RELEASED!!!

New Features of PHP7:

Following are the brand new features introduced in PHP 7:

  • Enhanced Performance
  • New Zend Engine 3.0
  • 2x faster than PHP 5.6
  • Reduction in Memory Consumption
  • Abstract Syntax Tree
  • Consistent 64-bit support
  • Enhanced Exception hierarchy
  • Many fatal errors converted to Exceptions
  • Secure random number generator
  • Removed old and unsupported SAPIs and extensions
  • The null coalescing operator (??)
  • Return and Scalar Type Declarations
  • Anonymous Classes
  • Zero cost asserts

Deprecated Features from PHP 5.6

Following are the features which are deprecated from PHP 5.6:

  • PHP 4 style constructors (methods with same name as the the class they are defined in) are deprecated but will be removed in future. The new version will emit E_DEPRECATED if one of the PHP 4 style constructors is used. Classes will remain unaffected which implement a __construct() method.
<?php
class foo {
    function foo() {
        echo 'I am the constructor';
    }
}

The above example will output:

Deprecated: Methods with the same name as their class will not be constructors in a future version of PHP; foo has a deprecated constructor in example.php on line 3
  • Undeclared static calls are deprecated but may be removed in the future.
<?php
class foo {
    function bar() {
        echo 'I am not static!';
    }
}

foo::bar();
?>

The above example will output:

Deprecated: Non-static method foo::bar() should not be called statically in - on line 8
I am not static!
  • The salt option for the password_hash() function has been deprecated so that developers cannot generate their own insecure salts. This function automatically generates a cryptographically secure salt in case developer does not provide any salt – this eliminates custom salt generation.
  • The capture_session_meta SSL context option has been deprecated. You can use SSL metadata through the stream_get_meta_data() function.

Migration from 5.6.x to 7.0.x

Although PHP 7 is a new release, we, at HostBreak, will make sure for our web hosting customers that your migration from PHP 5.6.x is hassle free. This version has been improved to provide optimal performance and language consistency. But we will suggest you to test it on a staging environment before applying it on entire website.

See also the migration guides for PHP versions 5.0.x, 5.1.x, 5.2.x, 5.3.x, 5.4.x, 5.5.x and 5.6.x at php.net website.

How to Enable PHP7 on HostBreak servers?

We, at HostBreak, strive to provide our customers latest versions of all technologies as soon as they are stable enough for secure usage. This is the reason all of our servers have now PHP 7 added on them. Enable PHP 7 on your account or a part of your account by going in cPanel and then the PHP Version Manager tool. Now you can enjoy explosive performance burst, less consumption of resources and exciting new features like scalar type declarations, the Spaceship Operator, anonymous classes, and many more.

php 7

Are Any Issues Expected?

We have not confronted any issues while testing default installations of the popular apps like WordPress, Joomla, Drupal etc. but as it’s a huge upgrade from PHP 5.3, some issues may occur. So, if you experience any issue feel free to contact our customer support.

contact-us-button