Simple URL Routing not working with CodeIgniter
$route['home'] = 'theWorksPlumbingController/index/home';$route['about'] = 'theWorksPlumbingController/index/about';$route['services'] = 'theWorksPlumbingController/index/services';
Might do it.. although I've never tried it with a setup like that. Typically in CI you make a method for each page like so:
class TheWorksPlumbingController extends CI_Controller { public function home(){ $this->load->view('templates/header'); $this->load->view('home'); $this->load->view('templates/footer'); } public function about(){ $this->load->view('templates/header'); $this->load->view('about'); $this->load->view('templates/footer'); } public function services(){ $this->load->view('templates/header'); $this->load->view('services'); $this->load->view('templates/footer'); }}
which are reachable via
http://www.example.com/index.php/theWorksPlumbingController/homehttp://www.example.com/index.php/theWorksPlumbingController/abouthttp://www.example.com/index.php/theWorksPlumbingController/services
And routable via
$route['home'] = 'theWorksPlumbingController/home';$route['about'] = 'theWorksPlumbingController/about';$route['services'] = 'theWorksPlumbingController/services';