With new product versions, Plesk adapts current versions of PHP. Therefore, it is important to correctly choose the version of PHP for developing your extension. The following table shows the recent Plesk product versions and the corresponding versions of PHP.

Plesk version PHP version
Plesk 12.0 5.5
Plesk 12.5 through Plesk 17.5 5.6
Plesk 17.8 7.1

First, you need to decide what versions of Plesk you want your extension to support. Keep in mind the following:

  • The more Plesk product versions are supported, the wider the audience for your extension.
  • The more Plesk product versions are supported, the less advanced SDK is available for you, since you would have to use the one for the earliest version of Plesk you plan to support.

Second, based on the selected range of Plesk product versions, you need to choose the suitable PHP version. Important considerations:

  • To ensure that all the selected Plesk product versions are supported, you should select the version of PHP that corresponds to the earliest selected Plesk version.
  • While new versions of PHP retain backward compatibility, keep in mind that sometimes incompatible changes are introduced. Refer to the PHP documentation to ensure that you are not using elements that are deprecated in more recent versions.

Note: PHP 7 introduces a number of backward incompatible changes relative to PHP 5.6.

For example, consider making an extension that supports both Plesk 17.5 and Plesk 17.8. Plesk 17.5 uses PHP 5.6, and Plesk 17.8 uses PHP 7.1. To support both, the extension should use the earliest version of PHP, which is 5.6 in this case, and the Plesk 17.5 SDK. Additionally, the extension should not use certain deprecated elements from 5.6, which were dropped in 7.1.

Finally, the completed extension must be thoroughly tested on all Plesk product versions that are supported to make sure it works correctly and is not influenced by differences in engines and SDK versions.