You will need to process the parameter from within whatever controller '/results' is routed to, eg:
if isset($_GET['q']) {
$searchCategory = $_GET['q'];
}
Another option would be to have q
as a function parameter on a controller method:
class MyController extends BaseController {
public function __construct() {}
public function getSearch($searchCategory) {
// Do Stuff
}
}
And this would be accessible via:
http://www.example.com/search/books