File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes get the <h:form> id of the current page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "get the <h:form> id of the current page" Watch "get the <h:form> id of the current page" New topic
Author

get the <h:form> id of the current page

avi lev
Greenhorn

Joined: Feb 17, 2012
Posts: 1
hi

first question on this great forum.....

i need to find on what page i'm at a cretin moment using a backing bean.

tnx.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15641
    
  15

Welcome to the JavaRanch, Avi!

JSF View definitions can contain more than one Form. I often do this.

Backing beans (Models) can exist in a many-to-many relationship with Views.

So there's no general mechanism you can use.

You can use the view binding mechanism to attach a particular UI control to a backing bean. You can then walk up the component tree to see what form it's in. That's not something the average webapp should be doing, though.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: get the <h:form> id of the current page
 
Similar Threads
Main
serialization and deserialization support in SOAP
EntityManager in Servlets Doubt
isThreadSafe
stay with same page after submiting form