Jquery jsp中的模式弹出窗口

Jquery jsp中的模式弹出窗口,jquery,jsp,simplemodal,modalpopups,modalpopup,Jquery,Jsp,Simplemodal,Modalpopups,Modalpopup,我希望我的表单在单击“生成”按钮时显示一个弹出窗口。当弹出窗口显示时,背景应淡出 下面是包含generate按钮的表单 <table class="ds_box" cellpadding="0" cellspacing="0" id="ds_conclass" style="display: none;"> <tr><td id="ds_calclass"> </td></tr> <

我希望我的表单在单击“生成”按钮时显示一个弹出窗口。当弹出窗口显示时,背景应淡出

下面是包含generate按钮的表单

<table class="ds_box" cellpadding="0" cellspacing="0" id="ds_conclass" style="display: none;">
        <tr><td id="ds_calclass">
            </td></tr>
    </table>
    <form name="cashreciept" method="POST" action="/ColdStorage/cashreciept" id="cashreciept">

        <div id="maindiv" >
            <div align="center">
                <p>&nbsp;</p>
                <p id="Title" align="center">CHANDNA COLD STORAGE
                </p>
            </div><br>
            <p align="center" style="font-size: 21px">CASH RECIEPT</p>
            <fieldset>
                <legend>CASH RECIEPT DETAILS:</legend>
                <table width="823" height="146" border="0" cellpadding="10">
                    <tr>
                        <td width="155">AGREEMENT  NO.: </td>
                        <td width="272" height="56"><input type="text" name="agrno" id="agrno" placeholder="Agreement No" value ="<%=agrno%>" >
                            <input type="button" name="Fill Details" id="fill details" value="FILL DETAILS" width="10px" height="10px" onClick="javascript:submitcash()"></td>


                        <td width="124">RECIEPT NO.:</td>
                        <td width="182" height="56"><input type="text" name="Recieptno" id="Recieptno" placeholder="Reciept no" value="<%=recno%>"></td>
                    </tr>

                    <tr>
                      <td>LOT NO.:</td>
                        <td height="78"><input type="text" name="lotno" id="lotno" placeholder="Lot No" value ="<%=agrno%>/<%=bags%>"> </td>


                        <td>DATE : </td>
                        <td height="78"><input onClick="ds_sh(this);" name="Date" readonly style="cursor: text" placeholder="Date" value="<%=date2%>" /><br /> </td>

                    <script type="text/javascript" src="js/calendar.js" lang="Javascript"></script>
                    </tr>
                </table>
            </fieldset>
            <p>&nbsp;</p>

            <fieldset>

                <legend>STORAGE DETAILS:</legend
                ><table width="823" border="0" cellpadding="10">
                    <tr>
                        <td height="41">NAME:</td>
                      <td width="689"><input name="Name" type="text" id="Name" placeholder="Name" width="400px" value="<%=fname%> <%=lname%>" size="40px"></td>
                    </tr>
                    <tr>
                        <td width="88" height="46">VILL/P.O:</td>
                      <td width="689"><input type="text" name="Village" id="Village" placeholder="Village" width="400px" value="<%=village%>" size="40px" ></td>
                    </tr>
                </table>
                <table width="823" border="0" cellpadding="10">
                    <tr><br><br>
                    <td width="153"><label>PRODUCT NAME :</label></td>
                    <td width="624"> POTATO</td>
                    </tr>
                </table>

              <table width="526" border="0" cellpadding="10">
                    <tr>
                        <td width="144" height="80"><p>Wt(QTY)</p>
                            <p>
                                <input name="Weight" type="text" id="weight" size="10" placeholder="Weight" value="<%=wt%>" >
                            </p></td>
                        <td width="144" height="80" ><p>BAGS</p>
                            <p>
                                <input name="Bags" type="text" id="bags" size="10" placeholder="Bags" value="<%=bags%>" >
                            </p></td>
                        <td width="144" height="80"><p>RATE
                            </p>
                            <p>
                                <input name="Rate" type="text" id="rate" size="10" placeholder="Rate" value="<%=rate%>" >
                            </p></td>
                    </tr>
                </table>
            </fieldset>
            <p>&nbsp;</p>
          <fieldset>
                <legend></legend>
                <legend>PAYMENT DETAILS:
                </legend>
                <table width="94" border="0" cellpadding="10">
                    <tr>
                        <td width="88" height="56"><p>AMOUNT</p>
                            <p>
                                <input name="Amount" type="text" id="amount" size="10" placeholder="Amount" value="<%=amt%>" >
                            </p></td>
                    </tr>
                </table>


              <table width="823" height="78" border="0" cellpadding="10">
                    <tr>
                        <td width="105" height="72"><p>ADVANCE
                            </p><p>
                                -
                                <input name="Advance" type="text" id="advance" size="10" placeholder="Advance" value="<%=advamt%>">
                            </p></td>
                        <td width="134"><p>ADD AMOUNT
                            </p>
                            <p>
                                +
                                <input name="Addamt" type="text" id="addamt" size="10" placeholder="Additional amt">
                            </p></td>
                        <td width="138"><p>LESS AMOUNT</p>
                            <p>
                                -
                                <input name="Lessamt" type="text" id="lessamt" size="10" placeholder="Less Amount">
                            </p></td>
                        <td width="130"><p>POL AMOUNT</p>
                            <p>
                                +
                                <input name="Polamt" type="text" id="polamt" size="10" placeholder="Pol Amount">
                            </p></td>
                        <td width="204"><p><strong>TOTAL AMOUNT</strong></p>
                            <p>
                                =
                                <input name="Total" type="text" id="total" size="10" placeholder="Total Amount" onfocus="javascript:totalamt()">
                            </p></td>
                    </tr>
                </table>

          </fieldset>
          <p>&nbsp;</p>
            <p>GATE PASS :
              YES
              <input name="radio" type="radio" id="YES"        onClick="MM_showHideLayers('Gatepass','','show','Print','','show')"  value="YES"/>
              NO 
              <input name="radio" type="radio" id="NO"     onClick="MM_showHideLayers('Gatepass','','hide','Print','','hide')"  value="NO">
          </p>
            <p>


钱德纳冷库


现金接收

现金收款明细: 协议编号: 接收编号: 批号: 日期:

存储详细信息: 姓名: VILL/P.O.:

产品名称: 马铃薯 重量(数量)

袋子

比率

付款详情: 数量

前进

-

追加金额

+

-

油料量

+

总金额

=

登机口通行证: 对 不

每当我点击generate按钮时,它就会调用javascript函数,而javascript函数又会调用另一个jsp页面,我想将其显示为弹出窗口

该jsp页面是

    <body>

    <fieldset id="gatepass" class="popup">

        <p align="center"><span style="size: 40px; font-size: 24px; alignment-adjust:middle">CASH RECIEPT</span></p>


        <table width="453" border="0" align="center" cellpadding="20px">
            <tr>
                <td width="188" height="51">RECIEPT NO : 
                    <label id="recno"><%=recieptno%></label></td>
                <td width="179">DATE : <label id="date"><%=date%></label></td>
            </tr>
            <tr>
                <td height="57">NAME : <label id="name" > <%=firstname%> <%=lastname%></label></td>
                <td>VILLAGE : <label id="village"> <%=vill%></label></td>
            </tr>
        </table>

        <p>&nbsp;</p>
        <table width="697" height="52" border="0" align="center" cellpadding="20px">
            <tr>
                <td width="205">AGREEMENT NO : <label id="agrno"> <%=agreno%></label> </td>
                <td width="149">LOT NO : <label id="lotno"><%=agreno%>/<%=bag%></label></td>
                <td width="151">BAGS : <label id="bags" ><%=bag%></label></td>
                <td width="174"> VEHICLE NO : <label id="vehicle"></label></td>
            </tr>
        </table>
        <p>&nbsp;</p>
        <table width="200" height="47" border="0" align="center" cellpadding="20px">
            <tr>
                <td> TOTAL AMOUNT : 
                    <label onloadstart="javascript:totalamt()" id="Totalamt" name ="total"></label></td>

            </tr>
        </table>
        <p align="center">
        <p align="center">
            <input type="button" name="Print" id="Print" value="PRINT">
            <input type="button" name="close" id="close" value="CLOSE" onClick = "closePopup();"  /> 

        <p>&nbsp;</p>
        <p>&nbsp;</p>
        <p>&nbsp;</p>

    </fieldset>
</div>

现金接收

接收编号: 日期: 姓名: 村庄:

协议编号: 地段编号:/ 袋子: 车辆编号:

总金额:

有人能告诉我怎么做吗?


<div id="divId"><jsp:include page="jspName"/></div>

 function MM_showHideLayers()
 {
   $('#divId').dialog({ modal: true });
 }
函数MM_showHideLayers() { $('#divId')。对话框({modal:true}); }

我不知道jsp:include的确切语法。你需要使用jsp:includeit,它已经显示为弹出窗口。我不知道如何淡出背景。我应该在这里放置这个div标记吗?@Divyang单击“生成”按钮,你可以在页面的任何位置放置div。。它调用函数openpage(){document.getElementById('gatepass').style.display='block';}该函数将jsp作为弹出窗口打开