CodeIgniter Forums
Nginx + PHP 7 + CI 3 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forum-5.html)
+--- Forum: Installation & Setup (https://forum.codeigniter.com/forum-9.html)
+--- Thread: Nginx + PHP 7 + CI 3 (/thread-64402.html)



Nginx + PHP 7 + CI 3 - no1youknowz - 02-16-2016

Hi.

Does anyone have an nginx config file for PHP 7 + CI 3?

If I do:

http://www.foo.dev/index.php/Campaigns

This works fine.

But if I do:

http://www.foo.dev

I get a 404.

I'm upgrading a V2.14 application to the current 3.x and I haven't developed in PHP in 6 months and forgotten all the little issues!

Thanks Dodgy


RE: Nginx + PHP 7 + CI 3 - ivantcholakov - 02-17-2016

http://www.foo.dev/index.php
http://www.foo.dev/index.php/

Do these work?


RE: Nginx + PHP 7 + CI 3 - keulu - 02-17-2016

did you specified a default route ? this route is still available ?


RE: Nginx + PHP 7 + CI 3 - V I R U S - 02-17-2016

Add this line to your nginx server part:


location / {
index index.html index.htm index.php;
try_files $uri $uri/ /index.php?q=$uri&$args;
}

Works!