USE DIFFERENT PHP for DIFFERENT PROJECT

in my example I use an extra PHP 7.3 for one project, despite the fact that Laragon has set PHP 8.0 for other projects.

  1. Create procfile for new php fastcgi process (Menu -> Laragon -> Procfile):

PHP 73 FastCGI: autorun “php-cgi.exe -b 127.0.0.1:9123” PWD=E:\WEB\laragon\bin\php\php-7.3.17-nts-Win32-VC15-x64

  1. Edit vHost for specific project and remove “auto” prefix from name:

 location ~ \.php$ {

    include snippets/fastcgi-php.conf;

    fastcgi_pass   127.0.0.1:9123;

    #fastcgi_pass unix:/run/php/php7.3-fpm.sock;

  }

  1. After start nginx, Menu -> Laragon -> run process at top, in my case “PHP 73 FastCGI”
  2. Viola!

Was this helpful?

0 / 0