But what about if you need to do this for the initial page? (i.e. you
don't have a page to put a command link on...)
I want this to be able to have bookmarkable URLs in my app, where
different URLs may map to the same view (JSP) -- for example, URLs
/app/users/tom and /app/users/jim would both be served by
/pages/user.jsp, and 'tom' or 'jim' would be passed into the JSP as a
request attribute/parameter.
The only way I've figured out so far to do this sort of thing is to
write a front-controller servlet that does the mapping from logical URLs
to physical JSPs and uses requestDispatcher.forward() to pass control
off to the Faces servlet.
It's been suggested that writing a custom navigation handler might be
another route to go; I haven't had a chance to explore that yet.
L.
Mike Kienenberger wrote:
<UICommand action="#{bean.process}">
// On bean
public String process()
{
// process
if (result1) return "processResult1";
if (result2) return "processResult2";
if (result3) return "processResult3";
if (result4) return "processResult4";
return "processResultDefault";
}
On 12/20/05, tony kerz <[EMAIL PROTECTED]> wrote:
at the risk of asking a stupid question:
if i wanted to have a user hit a url and have some processing take place
which then results in one of several available pages being displayed, in
struts i could easily accomplish that with an action class.
what would be the appropriate way to accomplish that functionality in a
JSF application?
something like dropping into an action method on a backing bean, but
without the initial page...