我想路由这样的东西: http ://myapp.com/mycontroller/...?x= ...
mycontroller 之后的所有内容都是未知的。我不知道路径,也不知道任何参数。路由后,路径和参数应显示为一个变量。
// route in routes.php
Router::connect('/mycontroller/*', 'Mycontroller::index');
// the index function of Mycontroller class
public function index($pathWithParameters) {
print_r($pathWithParameters); // something like: 'hello/world?name=mewel&id=123
}
这可能吗?