Routing System
The routing system is responsible for resolving a URL to a web page of specific content.
To add a new route to the system:
route::add($regex, $page_controller, $resolved_params, $options);
An example resolving the URL /en/books/123/book-name
to the page controller pages/book.inc.php
:
route::add('#^books/([0-9]+)/#', 'pages/book', 'book_id=$1');
Routing Modules
Routing modules are plug-n-play files containing a set of routes that can be dropped into LiteCart. The files are located in /includes/routes/
.