CodeIgniter Forums

Full Version: http://localhost/index.php
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I use htaccess to change url from http://localhost/public/ to http://localhost/ but when using index.php http://localhost/index.php, I got an error:

Controller App\Controllers\Index.php not found, but when I run http://localhost/public/index.php I got no error

Please help...
You have to do couple of steps to remove the public text from the URL

#1 Copy "index.php" and ".htaccess" files from the public folder and the paste on the root directory (eg. http://localhost)
#2 After pasting both files to the root folder, open the index.php from the root directory and edit the following line as shown below

$pathsPath = FCPATH . '../app/Config/Paths.php';
$pathsPath = FCPATH . 'app/Config/Paths.php';

Try this, It will work
It works, thnk you...
I am glad that it worked Smile