Welcome Guest, Not a member yet? Register   Sign In
Codeigniter 2.0 routes to subfolder of controller
#1

[eluser]Subshadow[/eluser]
Hi all,

Sorry for my bad English.

I updated my application to CI 2. After this update, I can't access to my subfolders in controller.

Example :

controller/home.php -> URL : http://mydomain.com/home/index OK

controller/admin/home.php -> URL : http://mydomain.com/admin/home/index White page

I try to replace the function set_directory to the old function, but same result.

Can you help me ?

Thanks.
#2

[eluser]toopay[/eluser]
before the upgrade, is it your controller (at sub directory folder) works?
#3

[eluser]Subshadow[/eluser]
Yes...

But I don't find any information about this.
#4

[eluser]toopay[/eluser]
ehm... are you passing some $_GET variable to that controller? if yes, change your $config['uri_protocol'] = 'PATH_INFO'.
#5

[eluser]Subshadow[/eluser]
No $_GET... Only a simple url to my controller
#6

[eluser]toopay[/eluser]
can you post your controller code here...
#7

[eluser]Subshadow[/eluser]
Yes, for example :

Code:
<?php
/**
* Classe Supervision
*
* Suppervision des sites
*
* @package    supervision
* @version    1.0.0
*/
class Supervision extends Controller_CI {

    /**
     * Controlleur
     */
    function __construct() {
        parent::__construct();
    }

    function index() {

        echo "ok";
    }
}
#8

[eluser]mlinuxgada[/eluser]
After update, any changes to .htaccess file ... Can you post your .htaccess here.

PS: And you have to extend CI_Controller class, not Controller_CI ;-).
#9

[eluser]Subshadow[/eluser]
[quote author="mlinuxgada" date="1297815216"]After update, any changes to .htaccess file ... Can you post your .htaccess here.

PS: And you have to extend CI_Controller class, not Controller_CI ;-).[/quote]


Ohhhh ! Thanks you very much !!! I'm a nooob !

It's Works Big Grin
#10

[eluser]mlinuxgada[/eluser]
Glad It helped.




Theme © iAndrew 2016 - Forum software by © MyBB