Here are two ways to install the base script package of the CodeIgniter framework and dependent libraries. The instruction is based on official documentation.
$PATH
by running the command:export PATH=/usr/local/php72/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin
composer create-project codeigniter4/appstarter ~/way/to/catalog/theproject
.htaccess
in the catalog public
:Options All -Indexes
Per line:
Options -Indexes
Options +FollowSymlinks
Per line:
Options +SymLinksIfOwnerMatch
If the root directory of the site is different from www
(usually the project files on CodeIgniter are located in the directory public
), then you can set the desired root directory in site settings or write the following directives in the file .htaccess:
# www/.htaccess <IfModule mod_rewrite.c> RewriteEngine on RewriteRule ^$ public/ [L] RewriteRule ((?s).*) public/$1 [L] </IfModule>