1. Knowledge Base
  2. >
  3. Results
  4. >
  5. How to Fix Error After MultiPHP Update

How to Fix Error After MultiPHP Update

If you previously used the PHP Selector plugin to manage the PHP version for your site and recently used the new MultiPHP Manager plugin to update PHP, you may have this error when visiting your website.

Missing MySQL Extension Error

Jump to a Section:

How To Fix "Missing MySQL Extension" Error

This error can be easily fixed by following the steps in the video below, and we've included a synopsis of the steps.


Before performing the steps below, HostGator strongly recommends creating a backup of the .htaccess file, which can be accomplished by following these steps.
  1. Locate the .htaccess file, right-click on it, and select Copy
  2. In the pop-up, it will provide the beginning of the path of where to store the backup. It will begin with /public_html, and you'll fill in the rest so that it reads /public_html/.htaccess.bak and click Copy File(s).
  3. Now you'll see the backup file in the main window named .htaccess.bak. You can always restore this by removing the .bak extension.

Here are the steps mentioned in the video above.

You may find some links below that will redirect you to your cPanel and its features provided that the following conditions are met:
  • You are logged into your Customer Portal. You can also log in after clicking the link.
  • The hosting package you are attempting to access is either a Shared or Cloud.
  1. Log into cPanel.
  2. Select File Manager.
  3. Locate and open the public_html folder.
    The public_html is the document root for your primary domain, which is why we're using it for this example. If you are doing this for a subdomain or an addon domain, you will want to complete these steps in the document root for that domain instead.
  4. Locate the .htaccess file, right-click on it, select Edit, and then click Edit again at the bottom of the pop-up window. If you need a guide to help you locate and edit your .htaccess, please refer to this article: How to Edit Your .htaccess File
  5. In your .htaccess, you should see two entries for PHP handlers. First, you'll have to identify the one that needs to be removed.

    The one you'll want to remove will look like one of these:

    # Use PHP71 as default
    AddHandler application/x-httpd-php71 .php
    <IfModule mod_suphp.c>
        suPHP_ConfigPath /opt/php71/lib
    #Use PHPedge as default
    AddHandler application/x-httpd-php-edge .php
    <IfModule mod_suphp.c>
        suPHP_ConfigPath /opt/phpedge/lib

    The one you want to keep will look like the one below.

    # php -- BEGIN cPanel-generated handler, do not edit
    # Set the “ea-php73” package as the default “PHP” programming language.
    <IfModule mime_module>
      AddHandler application/x-httpd-ea-php73 .php .php7 .phtml
    # php -- END cPanel-generated handler, do not edit
  6. To disable the PHP handler that you don't want, you can simply add a # at the beginning of each line, as we've done in the example below.
    #Use PHPedge as default
    #AddHandler application/x-httpd-php-edge .php
    #IfModule mod_suphp.c>
    #   suPHP_ConfigPath /opt/phpedge/lib
    Note: There may be more than one old PHP Handler entry in your .htaccess file. Repeat Step #6 for any additional entries. You should only have one entry that begins and ends with:
    # php -- BEGIN cPanel-generated handler, do not edit
    # php -- END cPanel-generated handler, do not edit
  7. Click Save Changes and then Close to close the editor.
  8. Pull up your site to check if the error is already gone.
If the instructions above do not work and your site is still displaying an error, please try and continue with these steps.
  • Search for another .htaccess file above your website's document root. This is the first .htaccess you saw in the File Manager before you clicked the public_html folder in Step 2.
  • Go ahead and open that .htaccess and check if there is a PHP handler in there. If there is, disable it. Pull up your site again to check.
  • If the error is still there, go to your cPanel's MultiPHP Manager, amd select your website name. Then, set your PHP version to inherit from the drop-down menu.

Related Topics:

Is There a Way To View and Update PHP Versions Without Going Through the File Manager?

The cPanel has a MultiPHP Manager that allows you to view and update your websites’ PHP versions. Please refer to this article to know more about this feature: What Version of PHP Are You Using?

We have also created a video guide about the use of the MultiPHP Manager for you. Just click this link to go directly to your cPanel’s MultiPHP Manager.

Where is My File Manager?

All website contents or files are stored inside your File Manager. To learn how to access your File Manager, please visit this article: How to Navigate Through File Manager.

How Do I Edit My Files Inside the File Manager?

Your website files can be manually created, modified, or removed from your File Manager. Please visit the article, How to Create/Edit/Delete a File Using the File Manager, for the details instructions on how to manage your website files inside the File Manager.

Additional Reference

What to Know Before You Upgrade PHP on Your Website

Still having errors or need additional assistance? HostGator's support is here to help, just reach out to us via phone or Live Chat!