Open cacacobra opened 1 year ago
I don't think it can be fixed without changing. It downloads file because x-httpd-ea-php70 doesn't exist in laragon.
I don't think it can be fixed without changing. It downloads file because x-httpd-ea-php70 doesn't exist in laragon.
Is there any possibility to configure Laragon to accept it?
I remembered small trick I've used for php per project setup, it will add that missing handler, so you don't have to change .htaccess. Try this:
Add this to the end of your apache config before IncludeOptional ...
, in my case it's C:/laragon/bin/apache/httpd-2.4.41-win64-VC14/conf/httpd.conf
And of course set correct path to the your php
ScriptAlias /php70 "C:/laragon/bin/php/php-7.0.33-Win32-VC14-x64"
Action application/x-httpd-ea-php70 /php70/php-cgi.exe
<Directory "C:/laragon/bin/php/php-7.0.33-Win32-VC14-x64">
AllowOverride None
Options None
Require all denied
<Files "php-cgi.exe">
Require all granted
</Files>
</Directory>
On my cPanel Server it includes the code below in my htaccess, so when i run my system in Laragon/Localhost it causes download file index.
Is there any way to avoid this without changing the htaccess?
Inside Apache configs maybe?
# php -- BEGIN cPanel-generated handler, do not edit # Defina o pacote “ea-php70” como a linguagem padrão de programação “PHP”.
# php -- END cPanel-generated handler, do not edit