Welcome Guest, Not a member yet? Register   Sign In
http://localhost/index.php
#1

I use htaccess to change url from http://localhost/public/ to http://localhost/ but when using index.php [font=Tahoma, Verdana, Arial, sans-serif]http://localhost/index.php, I got an error:[/font]

[font=Tahoma, Verdana, Arial, sans-serif]Controller App\Controllers\Index.php not found, but when I run [font=Tahoma, Verdana, Arial, sans-serif]http://localhost/public/index.php I got no error[/font][/font]

[font=Tahoma, Verdana, Arial, sans-serif][font=Tahoma, Verdana, Arial, sans-serif]Please help...[/font][/font]
Reply
#2

(This post was last modified: 09-13-2019, 11:49 PM by msjagan.)

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';
To
$pathsPath = FCPATH . 'app/Config/Paths.php';

Try this, It will work
Reply
#3

It works, thnk you...
Reply
#4

I am glad that it worked Smile
Reply




Theme © iAndrew 2016 - Forum software by © MyBB