This question is influenced by this answer by Balus C on the topic of f:viewParam . He writes in his answer that the first thing done by the the following code will “get the request parameter value by name id“.
<f:metadata>
<f:viewParam name="id" value="#{bean.id}" />
</f:metadata>
I understand that this feature is used in conjunction with GET requests but I fail to understand how the request parameter with the name “id” gets created in the very first place ?Also if I understood correctly “f:viewParam” goes hand in hand with the special includeViewParams query parameter for implicit navigation . Which of these two features is actually responsible for creating the request parameter ? Or is it none of these two ?
It’s just part of standard HTTP. To pass a request parameter with name
id, you’d basically need to have a link like followsSuch an URL is usually already provided elsewhere in your webapp. E.g.
See also: