I recently had a bit of a struggle to update PHP to Version 8.4 on a long standing web site.
Every time I did the upgrade via my Server Control Panel the update did not ‘take’.
The WP dashboard would just give me the dreaded; “You are running an unsupported version of PHP – 7.4” message.
Trying to get assistance from a Google Search and associate AI just threw a lot of gobbledegook at me.
AND THEN:
I recalled that certain older installations of WordPress used their .htaccess file for a lot of the initial heavy lifting so I loaded the ,htaccess file for this particular web site in question and found the following instruction right at the top:
#+PHPVersion#=php74AddHandler x-httpd-php74 .php#-PHPVersion
And how did I solve my PHP updating problem?
I deleted the above 4 lines completely, upgraded PHP via my Control Panel and am now set for any updates in the future.
If you have access to your web site file manager the .htaccess file is to be found in the public_html folder. You may have to turn on the option to view hidden files.
