팝업창에서 Opener로 Submit 하고 창닫기
opener의 window.name을 지정하지 못할 부득이한 경우..
아래와 같이 팝업에서 opener의 이름을 지정한 후 타겟을 정해주는 방식으로,
서브밋을 할수 있다.
처음엔 target="_opener" , target="opener" , target = window.opener
별것을 다 해봤다. 그러나 다들 새창으로 뜨거나 감감무소식!! ㅠㅠ
<script>
function goOpener(){
opener.name = "원하는 오프너 명";
document.frmName.target = opener.name;
document.frmName.action = "action Url";
document.frmName.submit();
self.close();
}
</script>
<form name="popup" action="opener.jsp">
<input type="button" value="오프너로 서브밋하기" onClick="javascript:goOpener();">
</form>