Skip to content

Commit

Permalink
PHP Configuration changes - howto
Browse files Browse the repository at this point in the history
  • Loading branch information
scottcwilson committed Jul 22, 2021
1 parent a9ee3b2 commit 6dd8ff0
Show file tree
Hide file tree
Showing 11 changed files with 61 additions and 13 deletions.
Binary file added content/images/multiphp.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added content/images/multiphpini.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added content/images/phpselector.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added content/images/phpselector_extensions.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added content/images/phpselector_options.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion content/user/payment/why_not_manual.md
Expand Up @@ -14,6 +14,7 @@ Older payment modules like `credit card` and `CEON Manual Card` are not recommen

So what are your options?

- Switch to a payment gateway. There are many [payment processors Zen Cart supports](https://www.zen-cart.com/content.php?14-Payment-Processing).
- Switch to one of the built-in payment gateways. There are many [payment processors Zen Cart supports](https://www.zen-cart.com/content.php?14-Payment-Processing).

- Use a plugin offering like [Authorize.net CIM Card on file](https://www.zen-cart.com/downloads.php?do=file&id=2272) which handles credit card details securely.

7 changes: 2 additions & 5 deletions content/user/running/memory_limit.md
Expand Up @@ -9,11 +9,8 @@ The PHP Memory Limit is the amount of memory a script is allowed to allocate, pe

In some environments, changing your PHP version can reset your memory limit setting. Go to the [version page](/user/admin_pages/tools/server_info/) after updating PHP to verify the setting of your PHP Memory Limit.

The process of updating your PHP memory is server-specific:

- Some hosts running cPanel provide PHP Selector, which has a page for PHP Options
- Some hosts running cPanel provide MultiPHP INI Editor
- Some hosts use `php.ini` files
The process of updating your PHP memory is server-specific,
depending on whether your hoster uses PHP Selector, MultiPHP Manager or some other mechanism. See [PHP Configuration](/user/upgrading/php_configuration/) for more information on setting PHP configuration.

Your hoster likely provides a knowledge base with instructions. Contact your hoster if you are unsure how to proceed.

Expand Down
3 changes: 3 additions & 0 deletions content/user/speed/admin_slow.md
Expand Up @@ -30,4 +30,7 @@ In addition to the settings mentioned above, additional settings you may wish to

Each of these settings has its own documentation.

### Software Changes to consider
Sometimes one of the widgets on the dashboard is the cause of the slowness. You can tweak these to improve performance at the cost of less functionality. For example, on busy stores, it might make sense to modify `admin/includes/modules/dashboard_widgets/RecentOrdersDashboardWidget.php` and turn off `$includeAttributesInProductDetailRows`.

You can try disabling specific widgets by modifying `admin/index_dashboard.php`.
4 changes: 3 additions & 1 deletion content/user/speed/max_file_upload.md
Expand Up @@ -29,7 +29,9 @@ The following settings control the length of time PHP is allowed to wait for an
Both of these need to be long enough (in seconds) for the time required for the slowest likely connection to upload the largest likely filesize.

### Changing these PHP Settings
It's best if those settings can be configured in the server's master PHP settings, or at least in the hosting-account's settings (if not in a control panel, then at least in a custom `php.ini` activated for just that user). Some of those settings (the times) can be set in code while the PHP scripts is executing. Check with your hosting company about the best way to change these settings for your unique needs. Some hosts do NOT allow you to change these; if yours does not, you may wish to change hosters.
It's best if those settings can be configured in the server's master PHP settings, or at least in the hosting-account's settings (if not in a control panel, then at least in a custom `php.ini` activated for just that user). Some of those settings can be set in code while the PHP script is executing. Check with your hosting company about the best way to change these settings for your unique needs. Some hosts do NOT allow you to change these; if yours does not, you may wish to change hosters.

See [PHP Configuration](/user/upgrading/php_configuration/) for more details.

### Zen Cart Admin Limit
In your Zen Cart [Admin > Configuration > Maximum Values](/user/admin_pages/configuration/configuration_maximumvalues/) screen, you'll find a *Maximum Upload Size* parameter. This is the number (in bytes) that Zen Cart checks to see if the file uploaded is small enough to suit maximum requirements. If the uploaded file is larger than this number, it will be rejected.
Expand Down
49 changes: 49 additions & 0 deletions content/user/upgrading/php_configuration.md
@@ -0,0 +1,49 @@
---
title: PHP Configuration
description: Changing PHP version or PHP Settings
category: upgrading
weight: 20
---

The process of changing your PHP version is server-specific:
- Some hosts running cPanel provide MultiPHP Manager tool
- Some hosts running cPanel provide PHP Selector
- Some hosts use a `php.ini` file

The process of changing PHP settings is also server-specific:
- Some hosts running cPanel provide MultiPHP INI Editor
- Some hosts running cPanel provide PHP Selector which has a page for configuring PHP settings
- Some hosts use a `php.ini` file

Your hoster likely provides a knowledge base with instructions. Contact your hoster if you are unsure how to proceed.

Once you are done changing PHP version or a PHP setting, use the
[Version](/user/admin_pages/admin_version/) link on the top right navigation menu to confirm that the change you made is recognized by Zen Cart.

## Changing PHP Versions with MultiPHP Manager

MultiPHP Manager provides a dropdown list of PHP versions; simply select the one that is right for your cart, select the domain from the list below it, and press Apply.

![MultiPHP Manager](/images/multiphp.png)

## Changing PHP Versions with PHP Selector

PHP Selector (Select PHP Version) provides a dropdown list of PHP versions; simply select the one that is right for your cart, select the domain from the list below it, and press Apply.

![PHP Selector](/images/phpselector.png)

## Changing PHP Configuration with MultiPHP INI Editor
The Basic Mode of MultiPHP INI Editor allows you to use a form to set some key variables, such as `memory_limit`. For other variables, it provides a file editor for you to use a `php.ini` file.

![MultiPHP Manager](/images/multiphpini.png)

## Changing PHP Configuration with PHP Selector

The PHP Options screen (launched from the Options tab) at the top of PHP Selector allows you to set common configuration variables for PHP.

![PHP Selector](/images/phpselector_options.png)

The PHP Extensions screen (launched from the Extensions tab) at the top of PHP Selector allows you to include PHP libraries.

![PHP Selector](/images/phpselector_extensions.png)

8 changes: 2 additions & 6 deletions content/user/upgrading/php_version.md
@@ -1,6 +1,6 @@
---
title: Updating your PHP Version
description: Changing PHP version after an upgrade
description: Moving to a higher PHP version after an upgrade
category: upgrading
weight: 20
---
Expand All @@ -9,12 +9,8 @@ After you go live with an upgrade, you will likely want to update your PHP Versi

You will want to run the latest PHP version which is appropriate for your Zen Cart version. See [Server Requirements for running Zen Cart](/user/first_steps/server_requirements/#php-version).

The process of changing your PHP is server-specific:
The process of changing your PHP is server-specific, depending on whether your hoster uses PHP Selector, MultiPHP Manager or some other utility. See [PHP Configuration](/user/upgrading/php_configuration/) for more information.

- Some hosts running cPanel provide MultiPHP Manager tool
- Some hosts running cPanel provide PHP Selector
- Some hosts use `php.ini` files

Your hoster likely provides a knowledge base with instructions. Contact your hoster if you are unsure how to proceed.

**Note:** In some environments, changing your PHP version can reset your memory_limit setting. Be sure to go to the [version page](/user/admin_pages/tools/server_info/) after updating PHP to verify the setting of your PHP Memory Limit. For more details, see [memory_limit](/user/running/memory_limit/).
Expand Down

0 comments on commit 6dd8ff0

Please sign in to comment.