Web Scripting Settings

Web Scripting Settings

For each website in your subscription you can turn on the support for the following programming and scripting languages:

  • Active Server Pages (ASP)
  • Microsoft ASP.NET (Windows hosting)
  • Server Side Includes (SSI) (Linux hosting)
  • PHP hypertext preprocessor (PHP)
  • Common Gateway Interface (CGI)
  • Fast Common Gateway Interface (FastCGI) (Linux hosting)
  • Perl
  • Python.

To turn on support for a particular scripting language, go to Websites & Domains > Hosting Settings, select the checkboxes next to the required scripting languages, and click OK. If you do not see the Hosting Settings link, contact your hosting provider.

Scripting_languages

Since Plesk 10.4, you can configure PHP settings individually for each website (or subdomain) in your subscription. To learn about custom PHP configuration, refer to the section PHP Settings.

PHP Settings

Plesk provides full support for the PHP scripting language, including support for multiple PHP versions and handler types out of the box. This topic explains how Plesk customers can manage PHP settings for their domains and subdomains from the Customer Panel.

PHP management on the domain level consists of three aspects:

  • Choosing the PHP version.
  • Choosing the PHP handler type.
  • Configuring additional PHP settings.

Note: You may only be able to manage some of the settings described below, or none at all, depending on your subscription settings. If you need to manage PHP settings that are unavailable to you, contact your hosting provider.

Choosing the PHP version

Plesk supports multiple PHP versions out of the box. To choose the PHP version for your domain or subdomain, go to Websites & Domains > PHP settings and select the desired PHP version from the menu:

If the desired PHP version is missing from the menu, contact your hosting provider.

Note that different PHP versions are not 100% compatible. A website written in PHP 5.3 may not function correctly if you configure PHP version 5.4 for the domain. If you are not sure what PHP version to choose, use the default setting or the latest version available. If your website is not displaying correctly, switch to a different PHP version.

Choosing the handler type

Plesk supports a number of different PHP handlers out of the box. To choose the PHP handler type for your domain or subdomain, go to Websites & Domains > PHP settings and select the desired PHP handler type from the menu:

If you are not sure what PHP handler type to choose, read about the different PHP handler types here.

Configuring additional settings

In addition to the PHP version and handler type, there are a number of PHP settings you can manage at Websites & Domains >PHP settings. These settings are mostly performance and security-related, but some of them may affect the operation of websites. Click the  icon next to an option to learn more about it.

Keep in mind that changing these setting may impact the performance of your website or even prevent it from displaying correctly. Unless you are sure what changes you need to make, it is recommended to keep the default values for all additional settings. If you make changes to the PHP settings and your website becomes slow or stops loading, revert all PHP settings to their default values.

Enabling PHP Acceleration

If your hosting provider allows it, you may be able to switch on PHP acceleration, also known as opcode cache module, for your website. If your website is written in PHP, enabling the opcode cache module can speed it up by a factor of two or more. To switch on PHP acceleration, go to Websites & Domains > PHP Settings and set the value of opcache.enable to "on".

Viewing the PHP settings

To view the PHP settings currently configured for the domain, including those configured on the server level, click View the phpinfo() page.

Inheriting PHP settings

Domains belonging to a subscription inherit the PHP settings defined on the subscription level. Subdomains inherit the PHP settings defined on the level of their parent domain. If you have the corresponding permissions on your subscription, you can change the PHP settings for every domain and subdomain independently of each other.

PHP Handler Types

Plesk provides full support for the PHP scripting language, including support for multiple PHP versions and handler types out of the box. This topic lists the PHP handler types that can be used in Plesk.

Handler typePerformanceMemory usageHandler details

Apache module

High

Low

This handler is only available in Plesk for Linux. It is the least secure option as all PHP scripts are executed on behalf of the apache user. This means that all files created by PHP scripts of any plan subscriber have the same owner (apache) and the same permission set. Thus, it is possible for a user to affect the files of another user or some important system files. You can avoid some security issues by turning the PHP safe_mode option on. This disables a number of PHP functions that have potential security risks. This may lead to inoperability of some web apps. The safe_mode option is considered to be obsolete and was removed in PHP 5.4.

ISAPI extension

High

Low

This handler is only available in Plesk for Windows. The ISAPI extension can provide site isolation if a dedicated IIS application pool is switched on for subscriptions. Site isolation means that the sites of different customers run their scripts independently. Thus, an error in one PHP script does not affect the work of other scripts. In addition, PHP scripts run on behalf of a system user associated with a hosting account. The ISAPI extension handler is not supported starting from PHP 5.3

CGI application

Low

Low

The CGI handler provides PHP script execution on behalf of a system user associated with a hosting account. On Linux, this behavior is possible only when the suEXEC module of the Apache web server is on (default option). In other cases, all PHP scripts are executed on behalf of the apache user. By default, the CGI handler is unavailable to Plesk customers.

FastCGI application

High

High

The FastCGI handler runs PHP scripts on behalf of a system user associated with a hosting account.

PHP-FPM application

High

Low

This handler is only available in Plesk for Linux. The PHP-FPM is an advanced version of FastCGI which offers significant benefits for highly loaded web applications.

 

  • 0 أعضاء وجدوا هذه المقالة مفيدة
هل كانت المقالة مفيدة ؟

مقالات مشابهة

Hosting Settings

Hosting Settings Per-website hosting settings can be divided into the following groups:...

General Settings

General Settings To view a website's general hosting settings, click Hosting Settings below the...

Web Server Settings

Web Server Settings Web server type depends on an operating system: Apache (with nginx) is used...

Powered by WHMCompleteSolution