php - CodeIgniter 4 : spark with multi public folders
one text
Solution:
Just find a solution: I've duplicated "spark" file into "spark-site1" and "spark-site2"
In theses files I add à line just after PHP open tag like:
#!/usr/bin/env php
<?php
define('PUBFOLDER', str_replace('spark-', '', basename(__FILE__)));
And modified the FCPATH definition to:
define('FCPATH', __DIR__ . '/public' . DIRECTORY_SEPARATOR . PUBFOLDER . DIRECTORY_SEPARATOR);
It works.
Source