CodeIgniter Forums
After update, problem with routing - 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: After update, problem with routing (/showthread.php?tid=64970)



After update, problem with routing - SubjectX - 04-15-2016

Hi,

I've upgraded from CI2.2.3 to CI3.0.6.

Function _fetch_uri_string() was deleted from URI.php and part of its functionality was moved to constructor. Since I set up some defined constants in this function, they were no longer available. Thats why I had to add _fetch_uri_string() to MY_URI.php (actually, I used my old file and function in it) and again call this function from Router.php like in older version of it.

So far so good. Function triggers and defined constants are being available.

BUT, I started getting this error:

An Error Was Encountered
Unable to load the requested file: login.php

I know that file is there and path that is called is localhost/login/
It works with previous version of CI, but stopped with this one, having file structure left intact..

How can I debug this problem?


RE: After update, problem with routing - cartalot - 04-15-2016

is it using an index method? if yes try adding it in the route, like login/index


RE: After update, problem with routing - SubjectX - 04-17-2016

I added login to routes but doesnt help either Sad

Any other idea?


RE: After update, problem with routing - SubjectX - 04-19-2016

I had to add temp solution to Loader.php into line 887:
$this->_ci_view_paths = array(VIEWPATH=>1);

Because _ci_view_paths had entry that had absolute path doubled like: d:\dev.local\d:\dev.local\application\views


RE: After update, problem with routing - RogerMore - 04-21-2016

Hey SubjectX,

I think it's a very bad idea to copy files from an older version of CI over the newer ones you are using know.
Things have have changed for a reason, and using older files is a recipe for disaster. You don't know what problems this will bring later on using your project.
Why not keep CI as it suppost to be and find another way to solve your problem?

As for your loading problem. When upgrading to your v3 of codeigniter, did you think to change your class file names like so: login.php -> Login.php.
http://www.codeigniter.com/user_guide/installation/upgrade_300.html?highlight=upgrading

Hope it helps,

Roger