View Full Version : How to submit the window from another window through javascript

Mar 7th, 2008, 03:27 AM
I am having a page from where i let user upload .csv file ,
As user browses and select file to upload and clicks upload button , on click of this upload button a new jsp is opened up on the parent window but it's not a pop up e.g.

<a href="<%=request.getContextPath()%>/hierarchy/popUp.jsp" class="modalEffect" >
<button type="button" class="ctaPrimary" onclick="checkFileType(uploadfile.value,this.form);" ><span><span><span>Upload</span></span></span></button>

In this popup.jsp the user is displayed either a message or error with ok and cancel button, Now when user clicks ok button the popup.jsp should close and the parent window should get submitted and a progress bar should be displayed on parent window if time taken for it's submission is more.

Mar 7th, 2008, 10:00 AM

replace finishUpload with whatever function you need to call on your parent window to clean up.