CodeIgniter Forums
help - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forum-28.html)
+--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forum-30.html)
+--- Thread: help (/thread-75580.html)



help - RAJEEV - 02-23-2020

i have a live runing project in codeinter, i am run this localhost in xampp server but i am found 404 error ,how i run this project in localhost server in xampp,please give me better solution. thank you


RE: help - saquibhasan - 02-23-2020

You haven't provide us details of your problem. Please share the flow you have followed to install CI.


RE: help - littlej - 02-24-2020

Hello Rajeev ! Instead of using Xampp (you can keep it though), use `Spark`. You will find all the info you need here: https://codeigniter4.github.io/userguide/installation/running.html

If you really want to use Xampp, copy CI to the folder `xampp\htdocs\`, for instance in 'xampp\htdocs\codeigniter4`. Then run Xampp and open `http://localhost/codeigniter4/www` in your browser. This is the overall principle.


RE: help - SVL - 02-24-2020

Take a look at Laragon i'm sure you won't go back to XAMPP after that, I didn't anyway.


RE: help - captain-sensible - 02-24-2020

i'm using CI in two ways : Desktop

with codeigniter in a directory called "CI" on Desktop ; if your on linux its a simple matter of
$ cd Desktop
$ cd CI
$ php spark server
//that starts up dev server and tells you addresss to go to eg:

bash-5.0$ cd Desktop/CI
bash-5.0$ php spark serve


CodeIgniter CLI Tool - Version 4.0.0-rc.3 - Server-Time: 2020-02-24 04:28:08am

CodeIgniter development server started on http://localhost:8080
Press Control-C to stop.
[Mon Feb 24 10:28:08 2020] PHP 7.4.1 Development Server (http://localhost:8080) started

so simply put http://localhost:8080 in the address bar (top) of a web browser


One simple advantage of running from Desktop if your on Linux is that xampp is usually installed
at something like /opt on linux and since it it not located in /home/user space everything comes under root permissions which is a total pain when running your linux OS as a normal user and try to edit anything.




The other way i'm using it is not xampp; but simply using the inbuilt apache server


RE: help - littlej - 02-24-2020

Spark doesn’t require Xampp. It has an integrated web server.
The advantage of using Xampp is to be able to use it for other projects/frameworks.


RE: help - dave friend - 02-24-2020

(02-24-2020, 04:16 AM)littlej Wrote: Spark doesn’t require Xampp. It has an integrated web server.
The advantage of using Xampp is to be able to use it for other projects/frameworks.

The other advantage of Xampp is that you can create a development server that is exactly (or nearly so) the same as the production server.