I am not sure. I think the id should be also dynamic: id = parameters.get(parameters.getIndexedCount() - 1);
Martin Grigorov Wicket Training and Consulting https://twitter.com/mtgrigorov On Wed, Jan 13, 2016 at 6:17 PM, Marcel Barbosa Pinto < [email protected]> wrote: > Hmm, cool... this will work for me as the last index will always be the > ${id}, tks! > > > > > > On Wed, Jan 13, 2016 at 3:08 PM, Martin Grigorov <[email protected]> > wrote: > > > Hi, > > > > Mount just "page" and use PageParameters indexed parameters to read/write > > the categories. > > > > Martin Grigorov > > Wicket Training and Consulting > > https://twitter.com/mtgrigorov > > > > On Wed, Jan 13, 2016 at 6:04 PM, Marcel Barbosa Pinto < > > [email protected]> wrote: > > > > > Hi guys, > > > > > > I have to mount a page with an URL that contains zero or more > > "categories". > > > > > > /page/${id} > > > /page/vahicles/${id} > > > /page/vahicles/cars/${id} > > > /page/vahicles/cars/honda/${id} > > > > > > > > > The "/page" is fixed while the others vehicles, cars and honda is like > a > > > category tree only for SEO needs. > > > > > > In a rewrite framework I can create a regex for these params. > > > How can I achieve this in Wicket without fixing the parameters? > > > > > > Instead of that: > > > > > > /page/${cat0}/${id} > > > /page/${cat0}/${cat1}/${id} > > > /page/${cat0}/${cat1}/${cat2}/${id} > > > > > > I would like to do something like this pseudo regex: > > > > > > /page/#{(.+/)?(.+/)?(.+/)?}/${id} > > > > > > > > > Thanks; > > > > > > > > > -- > > Marcel Barbosa Pinto > 55 11 98255 8288 >
