09-20-2019, 06:57 AM
[/url][url=https://codeigniter4.github.io/userguide/incoming/routing.html#placeholders]I already asked a similar question, but alas, the response I never received.
Reading the documentation on the link, I notice that the placeholder "{locale} " CANNOT be used as a route for example:
But clicking on another link, there I see that this placeholder CAN be used as a stand, which I do...
Only here there is one problem when I use method "->back('Select_News');" in the browser line appear these strange characters "http://example.ru/%7Blocale%7D/News/Post/1", although should be EN or RU, in dependence where initially I was.
How can I fix this ?
Reading the documentation on the link, I notice that the placeholder "{locale} " CANNOT be used as a route for example:
PHP Code:
$routes->add('{locale}/news/post/id', 'App\News::posts\$1', ['as' => 'Select_News']);
$routes->add('{locale}/news/main', 'App\News::posts', ['as' => 'All_News']);
Only here there is one problem when I use method "->back('Select_News');" in the browser line appear these strange characters "http://example.ru/%7Blocale%7D/News/Post/1", although should be EN or RU, in dependence where initially I was.
How can I fix this ?