Re: How to reproduce specific Friendly URL ?

Splash Forums PrettyFaces Users How to reproduce specific Friendly URL ? Re: How to reproduce specific Friendly URL ?

#20771

LaChamelle
Participant

I can have more than two levels. This list is not exhaustive.

  • /site/channel/contentOne
  • /site/channel/channelToto
  • /site/channel/channelTiti/fooChan
  • /site/channel/channelTiti/fooChan/barChan
  • /site/channel/channelTiti/fooChan/barContent
  • /site/channel/channelTiti/fooChan/barChan/tataChan
  • /site/channel/channelTiti/fooChan/barChan/totoContent

So the following mapping will not match all the previous examples ?

<url-mapping id="root">
<pattern value="/site/#{siteName:bean.siteName}" />
<view-id value="/faces/viewSite.jsf" />
<action>#{bean.loadSite}</action>
</url-mapping>
<url-mapping id="channel" parentId="root">
<pattern value="/#{channelName:bean.channelName}" />
<view-id value="/faces/viewChannel.jsf" />
<action>#{bean.loadChannel}</action>
</url-mapping>
<url-mapping id="subChannel" parentId="channel">
<pattern value="/#{subChannel:bean.subChannelName}" />
<view-id value="/faces/viewSubChannel.jsf" />
<action>#{bean.loadSubChannel}</action>
</url-mapping>

I appreciate the time you spend to answer me ;)