Is it possible to run PHP 5.6 and PHP 7.4/8.0 on the same server?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Is it possible to run PHP 5.6 and PHP 7.4/8.0 on the same server?

    hi, After a lengthy break, I'm happy to return to WHT. For some reason, I was also unable to access my old account.
    I've used dedicated server for nearly a decade and need to migrate to PHP7.4 or 8 as soon as possible.
    The website is built using a custom CMS (which, unfortunately, is still running on PHP 5.6) and WordPress. Moving the CMS to PHP 7+ is taking longer than expected, but at the very least, I'd like to upgrade the WordPress portion to the most recent PHP version.
    Is it possible to run two versions of PHP on a bare metal server at the same time? EasyApache4 supports two PHP versions.

    #2
    Your php.ini file can control the PHP version; just place what you need in there.

    Comment


      #3
      On cPanel/WHM, PHP 5.6 that's no longer supported and should not be used. If you're using CloudLinux, you're lucky since it includes a feature called HardenedPHP/PHP Selector that protects older PHP versions.

      Comment


        #4
        If you don't use Cloudlinux, be sure to fully protect your webserver and be aware of any vulnerabilities introduced by 5.6.
        But why use an older version of PHP when the current PHP has so many advantages?
        You should consider updating your CMS to support the newest PHP version as a top priority.

        Comment


          #5
          While changing PHP versions at the directory level is possible, I do not advise it. Use a production domain to develop the website using PHP 7+ or 8+ and use a robots.txt file to restrict indexing.

          Comment

          Working...
          X