Как удалить публику из URL в Codeigniter 4
// codeigniter-4
-----------------------------------
Step 1: Change in App.php File
-----------------------------------
public $baseURL = 'http://localhost:8080';
To
public $baseURL = 'http://localhost/your_project_name/';
* And the second change in the app.php file:
public $uriProtocol = 'REQUEST_URI';
To
public $uriProtocol = 'PATH_INFO';
--------------------------------------
Step 2: Copy index.php and .htaccess
--------------------------------------
--> Visit inside public directory. And
copy index.php and .htaccess to codeigniter app root directory.
------------------------------
Step 3: Change In index.php
------------------------------
$pathsPath = FCPATH . '../app/Config/Paths.php';
change TO
$pathsPath = FCPATH . 'app/Config/Paths.php';
Rht