Java

GET,POST 팝업띄우기

griffy 2009. 8. 23. 19:58

1. GET방식  
strUrl = "/include/contentXf.jsp?xtmPagego=/common/Planx.xtm&strBrdCompCode="+brd_comp_code+"&strBrdCompName="+ strBrdCompName+"&strStDate="+ st_date + "&strEdDate="+ed_date+ "&strFrmType=addRow" + "&stFrmKey="+frmKey;
 window.open(strUrl, 'frmPop', 'status=yes,resizable=yes,width=970,height=520, top=200, left=200');     

2. POST방식  
window.open("about:blank", 'frmPop', 'status=yes,resizable=yes,width=970,height=520, top=200, left=200');     
  frm.xtmPagego.value = "/common/Planx.xtm";
  frm.strBrdCompCode.value = brd_comp_code;
  frm.strBrdCompName.value = strBrdCompName;
  frm.strStDate.value = st_date;
  frm.strEdDate.value = ed_date;
  frm.strFrmType.value = "addRow";
  frm.stFrmKey.value = frmKey;

  frm.target = "frmPop";
  frm.method = "POST"
  frm.action = "/include/contentXf.jsp";
  frm.submit();