题
I want to route something like this: http://myapp.com/mycontroller/...?x=...
where everything after mycontroller is unknown. I dont know the path and i dont know any of the parameters. After routing the path and parameters should appear as one variable.
// 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
}
Is this possible?
没有正确的解决方案
不隶属于 StackOverflow