Okay, this is a little complex, so hopefully I can describe it well so as not to confuse anyone.
We have a need for the following. We need a reusable set of actions, JSPs, etc. that operate in a popup to allow the user to search for a medical provider. That's easy enough. The catch is this. The reason for a popup is because the UI requirement is that the user perform the search and then (as transparent as possible to them) have the page refresh the portions of the display that say what medical provider is currently selected. So you might have a page. In other words when the search is performed a hidden form field will get updated (via Javascript currently) with selected Provider ID. And then N number of fields are going to be populated with some data to let the user know which provider has been selected. The trick is that since we're using Javascript currently the Javascript is basically statically calling form names and form fields and changing data based on what it's getting from the search action. So something like this. <script type="text/javascript" language="JavaScript"> <!-- function callOnloadFunctions() { updateParentAndCloseSelf(); } function updateParentAndCloseSelf() { changeParentFormValue('medicalInfoForm', 'hospital', '<c:out value="${chosenProvider}" />'); changeParentDOMElement('hospitalLabel', '<c:out value="${chosenProvider}" />'); window.close(); } //--> </script> Obviously problem #1 is that this JSP page can't be used on other views because it references by name the name of the form. I'm not sure how to dynamically get this to the JSP page without passing around a token of some kind or passing around values in the request stream. That seems like it could get ugly. Plus if I have to update, visually, more than just the name of the hospital, for example, how would I handle that? Imagining ANOTHER JSP page with separate Javascript. function updateParentAndCloseSelf() { changeParentFormValue('anotherForm', 'hospital', '<c:out value="${chosenProvider}" />'); changeParentDOMElement('hospitalLabel', '<c:out value="${chosenProvider}" />'); changeParentDOMElement('hospitalAddressLabel', '<c:out value="${chosenProvider}" />'); changeParentDOMElement('hospitalStateLabel', '<c:out value="${chosenProvider}" />'); window.close(); } In short, it could get REALLY ugly. Now another option is that we actually give in (I say give in because it would mean a page refresh, something that might not go over well), submit the form, but don't save the data to the database yet, and then somehow via request or session retain any other field data they may have changed for when we hit the page again, without saving it to the database. Okay, hopefully that makes some sense. Basically we want a popup that performs a search, updates some data on the page and in the form on the page, without actually doing the final submit and save. And we'd like it to be reusable, if possible. So far we can't think of the best way to approach this, in terms of the UI. Hopefully someone gets the question and can help. If not I understand, believe me. Preston --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]