AjaxSubmitButton in a ModalWindow using a Panel as content doesn't work if the ModalWindow component is itself embedded in a Form.

The issue is that ModalWindow tacks its content on as a <div> on the <body> element, which places it outside the original <form> element.

If we fix ModalWindow to inject its Panel content into the middle of the page where the component actually lies, then all the CSS is messed up - it uses position: absolute, which will work fine until you put the ModalWindow component inside something that is position: relative;

If you add a <form> to the ModalWindow's Panel, then the nested Form resolution stuff removes the <form> element because it thinks it has a parent <form>, even though when it's rendered it's actually outside it.

I'm not sure how to fix this, or even if it's possible to.
Maybe we can make the nested form hierarchy check stop traversing its parents at ModalWindow boundaries, and require than things inside a ModalWindow have their own Form?

Al

Reply via email to