Routes.php
$router->add('/user[/]?{name:[a-zA-Z]*}', [ 'controller' => 'test', 'action' => 'index' ])->via('GET')->setName('default');
In Volt template file:
{{ link_to(['for': 'default', 'name' : 'Dejan'], 'Dejan') }}
From some reason, I'm getting this path:
/wl/public/user[/]?Dejan
but it should be:
/wl/public/user/Dejan
What am I doing wrong?
Thanks!