Routing in CodeIgniter — a practical guide to CodeIgniter routing with clear examples you can reuse in real projects.
CodeIgniter Tutorial Series (11/74). Prefer one article? Read the complete CodeIgniter tutorial.
Short description
Define routes in `app/Config/Routes.php`. You can use placeholders, groups, and named routes for clean URLs.
Basic routes
$routes->get('/', 'Home::index');
$routes->get('about', 'Pages::about');
$routes->get('posts/(:num)', 'Posts::show/$1');
$routes->post('contact', 'Contact::submit');