Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

rich modal window submission

 
Zack Marrapese
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am working on a project in which I would like to pop up a window which will do some basic form submission. After this I would like to return to the previous view.

I chose the rich:modalPanel component for this. I have no trouble showing and hiding the window. However, when I try to call any actionListener from a command object within the modal panel, it does not reach the actionListener. Here is the relevant portion of my code:

TEMPLATE:


modalPanel defined:


Backing bean:


However, the actionListener is never even reached (confirmed in debug). Any suggestions?
 
Zack Marrapese
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found out my problem. According to the manual, there are some limitations on submitting from a modal pane:
1.) A form must be declared within the modal panel (and therefore, the modal panel must be defined outside any existing form to avoid nested forms).
2.) The modal panel can't be included onto the page. It must be in the base of the page.

Hope this helps others that have this problem.
~Zack
 
Venkat Sadasivam
Ranch Hand
Posts: 139
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
To keep in more simpler you can even think of having an iframe inside you modal dialog.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic