KarolGil
6 months ago
2215
14
Servers

Php version and .htaccess

Posted 6 months ago by KarolGil

I have this server structure.

/ - php version 5.6 set for the entire server as default

/.htaccess

<FilesMatch "\ .php $">
SetEnv CGI_HANDLER php73
</ FilesMatch>

/laravel/.htaccess

AddType application / x-httpd-php72 .php5 .php4 .php .php3 .php2 .phtml

Can anyone explain me why and how it works? I mean, first of all, writing to the file /laravel/.htaccess. Because when the /laravel/.htaccess file is empty, then the laravel script does not work.

The server / hosting has different php versions to choose from 5.6, 7.0, 7.1, 7.2, 7.3, 7.4

This situation applies to laravel version 5.8

Please sign in or create an account to participate in this conversation.