CodeIgniter Forums
CI4 in localhost - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: Installation & Setup (https://forum.codeigniter.com/forumdisplay.php?fid=9)
+--- Thread: CI4 in localhost (/showthread.php?tid=76602)

Pages: 1 2


RE: CI4 in localhost - jreklund - 08-19-2020

You need to set-up a virtual host; https://forum.codeigniter.com/thread-77200.html


RE: CI4 in localhost - InsiteFX - 08-20-2020

My shared hosting server is not using a virtual host, I do use a virtual host here at home.

May be it is something my hosting provider is doing WebHostingBuzz.


RE: CI4 in localhost - Tamer - 08-27-2020

Hello,
Trying to install ci4 on my local raspberry, and using Composer installation, I get :
CodeIgniter development server started on http://localhost:8080
When I put "php spark serve"
But nothing at this adress except a "connection failed"

Now if I try to use URL like this : http://192.168.0.104/ci-install/public
 
I get this message :

systemDirectory, '/ ') . '/bootstrap.php'; /* *--------------------------------------------------------------- * LAUNCH THE APPLICATION *--------------------------------------------------------------- * Now that everything is setup, it's time to actually fire * up the engines and make this app do its thang. */ $app->run();

Donnu what's mean
Donnu what I've to do

My App.php :

PHP Code:
public $baseURL 'http://192.168.0.104/ci-install/public/'

Can you please help me ?


RE: CI4 in localhost - InsiteFX - 08-28-2020

Did you try it like this?

PHP Code:
public $baseURL 'http://localhost:8080/'



RE: CI4 in localhost - Tamer - 08-28-2020

I just tried, but nothing as changed, always the same message.

But I remember seeing this part of the message in a file :
systemDirectory, '/ ') . '/bootstrap.php';

Yeah, in the var/www/html/ci-install/public/index.php, there is a line  :
$app = require rtrim($paths->systemDirectory, '/ ') . '/bootstrap.php';

I don't understand why part of this script appeared on a web page
Do you have an idea ?


[Image: 1598614242-qzdza.png]


RE: CI4 in localhost - jreklund - 08-28-2020

You don't have PHP correctly installed. So it just displays the code and never runs it.

Spark can only be used if you are using the Raspberry Pi as an desktop computer, not an server. So you need to install real apache+php server.


RE: CI4 in localhost - Tamer - 08-28-2020

Indeed, the problem was that the php7.3 module of apache2 was not activated

I had to a2dismod a "mpm" module before activating the php7.3.load module into /etc/apache2/mods-enabled

And after that I had to give apache2's www-data access to the cache in var/www/html/myproject/writable

Thanks for your help !