|
Hi,
I am populating one popup window value to the parent window but my requirement is to populate times and again to the same field with comma separated values. What happens now is after populating one value to my parent window when i again open the popup and select a diff value , my previous value is getting replaced by second value. I want whenever i select any other value it should be appended with the first value by a comma.
Any help will be appreciated .
My Parent window javascript code is :
function searchEmployees(){
var path = '<%=request.getContextPath() %>/secure/employeeForm.do';
var sepwin = window.open(path,'Employee_Code_Finder', 'height=600,width=600,status=1,scrollbars=yes,resizable=yes');
sepwin.moveTo(((screen.availWidth/2)-(50)), ((screen.availHeight/2)-(300)));
sepwin.focus();
}
My popup window javaScript code is :
function selectCode(code) {
window.opener.document.useForceReportForm.employee_id.value = code;
alert("empid is " + code + " selected.");
window.close();
}
|