Hi,

I have what must be a newbie question.

I am trying to use the TabbedPane component Tomahawk.
I am using MyFaces 1.1.1.

Let's say I have 3 tabs:

Tab1, Tab2 and Tab3

Is it possible to capture the click of a Tab? This component doesn't have an action attribute.

If you are on Tab1 and click on Tab2, how do I get to that event?
It seems that onClick should at least get it from the _javascript_ side. However, this doesn't seem to work as anticipated. Instead, using onClick in the t:panelTab  works for the active tab, and using onClick in t:panelTabbedPane captures it for all tabs. I want to capture clicking on Tab2 and Tab3 as separate events.

         <t:panelTabbedPane bgcolor="#DDDDDD" >

                 <t:panelTab id="tab_staffDetails" label="#{labels.staffdetails}" rendered="true" >

Ideally, I would like the the tab to have an action attribute so I could treat it like a submit button. Clicking it would save the current tab then display the clicked on tab.

Specifically, I want to prompt the user to save their work when the move from tab to tab. It is VERY possible that they may fill out a tab, go do something else and lose that tabbed page of work due to a timeout or they may just assume that their work was already persisted to the datasbase. Probably, I may have separate JSP's to represent each tab. I have concerns that I have too many tabs (5) and too many fields (several forms, many fields each). I have also considered just "making" my own tabbed pane with a clever use of CSS and h:commandButton's.

Anyone have any experience with designing a tabbed interface and want to comment on their feelings about it. To date, I have mostly stuck with a "wizard" approach (Next, Next Finish/Save). A tabbed pane interface (while it looks cool) seems cumbersome and difficult to split up among multiple developers.

I am only doing a tabbe interface because I was asked to use this metaphor. In reality, I don't think that it is necssarily any more user friendly than a wizard or seqential approach?

Thanks for any input.

Kevin Hutson

Reply via email to