CodeIgniter Forums
codeigniter 4 on server - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24)
+--- Thread: codeigniter 4 on server (/showthread.php?tid=79225)



codeigniter 4 on server - Rarach - 05-14-2021

    Hi, sorry my question may be really stupid, but I have been looking for solution for quite long time, so...

What is correct method when i want to move my project from localhost onto webserver? (my is "http://firstname.username.cz/codeigniter/project-name/").


I have tried to do so many methods. now I have just moved default appstarter project as it was to "project-name" folder and:

in /config/App.php I've changed $baseURL and $indexPage  to:
    public $baseURL = 'http://firstname.username.cz/codeigniter/project-name/';
    public $indexPage = '';


in "project-name" folder I've created .htaccess with following line "RewriteRule ^(.*)$ ./public/index.php?/$1 [L,QSA]"

but I still get [img]

translated "An internal error occurred while processing the request. This is probably an error in the .htaccess file."

Do I have to change .htaccess to something else, split project into 2 folders (public and rest) or just something completly different?

Thanks a lot for any advice, have a nice day Smile