I am quite new to JSF. However I previously worked nicely with Struts 1.x and 2.x I have a question related on how to get some properties for say a page when user is first presented with. For example I am experiencing with a login page. I would like when I call http://localhost/jsfStart/index.xhtml to route this request through a bean that sets some of the page contents In Struts I mapped an action.
This article on filters would be very useful Filters It should get you through a basic filter for incoming requests, try some examples given in the article,
if you encounter any issues then post it here and I can help
Thank you for hint. So if I understood correct is that I can basically map my LoginCheck servlet in the web.XML
however this will mean that all my further post requests will go through this LoginCheck if I map it with <URL>/*<URL>
although the form action is another servlet?
The Filter mapping that you specify in the web.xml will decide whether to route all your requests(/*)
or requests to a specific servlet(LoginCheck). Also, you can map your filter to more than 1 servlet and you can map several filters to 1 servlet too.
Your form action can be another servlet if you do not wish to filter the requests
We can walk to school together. And we can both read this tiny ad:
a bit of art, as a gift, the permaculture playing cards