Francesco
Francesco

Reputation: 2382

Passing parameters between JSF pages

actually I use h:link with h:param to pass parameters from one page to another.

The problem is that so the parameters come in the url too and in some cases I don't want it (the page should not be bookmarkable).

How can I do? What should I use?

Thank you in advance Francesco

Upvotes: 0

Views: 3168

Answers (1)

Pablo Santa Cruz
Pablo Santa Cruz

Reputation: 181270

You can use an h:commandLink instead of h:link. Your page invocation will be done through a POST command instead of a GET command. Hence, parameter will not show up in URL.

Here's is an example I got from here:

<h:commandLink>
    <h:outputText value="welcome"/>
    <f:param name="outcome" value="welcome"/>
</h:commandLink>

Upvotes: 3

Related Questions