Codeigniter 3 controller in sub folder |
In controller I have a folder named "landing".Inside this folder I have a controller name "Landingg.php"
code ------ <?php defined('BASEPATH') OR exit('No direct script access allowed'); class Landingg extends CI_Controller { public function __construct() { parent::__construct(); $this->load->helper('url'); } public function index() { echo 12; } } when I hit the url "http://localhost/ci/landing/landingg/" it shows object not found.Plz help how to implements and call controller with in sub folder in codeigniter 3 (05-29-2017, 10:09 AM)[email protected] Wrote: In controller I have a folder named "landing".Inside this folder I have a controller name "Landingg.php" Create file MY_Router.php in application/core directory with code: PHP Code: <?php
Sorry, I think my code is wrong for your situation.
First of all check your route config. E.g. $route['landing/landingg'] = 'landing/landingg/index'; And your folder must be upper case. Landing.
Did you set your base_url in ./application/config/config.php ?
What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
|
Welcome Guest, Not a member yet? Register Sign In |