Set Default Controller under Sub-Directories in CI3 - 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: Set Default Controller under Sub-Directories in CI3 (/showthread.php?tid=435) |
Set Default Controller under Sub-Directories in CI3 - vrsotto - 12-04-2014 Hi guys, just wondering if any of you have encountered this issue. i was testing, running CI3 under in my local development. my current development setup, is i moved "application" and "systems" folders above the main root, the rest of the files is on under "public_html" including the main index.php and .htaccess (thats it, didn't touch anything after those). by default the application is running with the welcome message of CI3. Then, with the changes. in the config.php i set the following: $config['base_url'] = ''; $config['index_page'] = ''; in routes.php: $route['default_controller'] = 'admin/welcome'; and .htaccess <IfModule mod_rewrite.c> Options +FollowSymLinks RewriteEngine on # Send request via index.php RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php/$1 [L] </IfModule> CI is not working anymore. Why? Can anyone please help, how i can make default controller work under the "admin" folder. Thanks in advanced RE: Set Default Controller under Sub-Directories in CI3 - sv3tli0 - 12-04-2014 Fast hack about your problem is making your MY_Router at app/core folder: PHP Code: <?php This way you will be able to set directory for default controller Or you can even set PHP Code: <?php RE: Set Default Controller under Sub-Directories in CI3 - vrsotto - 12-04-2014 Hi sv3tli0, so, is this bug for CI3? RE: Set Default Controller under Sub-Directories in CI3 - Narf - 12-04-2014 No, it's not a bug. Read this thread: http://forum.codeigniter.com/thread-160.html |