Re: multi-language url rewiting. Is it possible?

Splash Forums PrettyFaces Users multi-language url rewiting. Is it possible? Re: multi-language url rewiting. Is it possible?



I played with both h:link and pretty:link,

the beaviour is quite different:

1. <h:link>

I tried two links of this type, the one suggested by Christian:

<h:link outcome="/pages/main/welcome.jsf">

and the following one:

<h:link outcome="/pages/main/welcome.jsf" value="#{}">
<f:param value="#{localeChanger.languageCode}" />

the results are the same: the url becomes http://localhost:8080/mtc/pages/main/welcome.jsf, so the out-bound seems to misbehave.

2. <h:link> with mapping-ID

<h:link outcome="pretty:welcome" value="#{}">
<f:param value="#{localeChanger.languageCode}" />

here the url becomes http://localhost:8080/mtc/pages/main/welcome.jsf?com.ocpsoft.mappingId=welcome

…still not working

3. <pretty:link>

<pretty:link mappingId="welcome">
<f:param value="#{localeChanger.languageCode}" />

here the url becomes http://localhost:8080/mtc/it/main/welcome, so the out-bound works as expected.

I used the configuration we discussed in the previous posts, why h:link doesn’t work as expected?

Thanks in advance