0

現在、私はこのように機能するプロジェクトを持っています

  1. フォームに記入し続ける
  2. ボタンをクリックすると、新しいウィンドウがポップアップします
  3. popupwindow にデータを入力して送信する
  4. ポップアップ ウィンドウが閉じ、そのウィンドウのデータがデータベースに保存されます
  5. 親フォームへの入力を続行し、データを保存します

ポップアップ ウィンドウを jQuery UI ダイアログに置き換えて、同じ操作を実行します (ステップ 2 3 4)。

ここにいくつかのコード

 $( "#rtrDialog" ).dialog({  
     autoOpen: false,     
     height: 300,
     modal: true,
     width: 350,  
     buttons: {        
         "Continue..": function() {
             alert("Button Clicked");
             var url = "contractDetails.htm";
             window.open(url, '_blank');
         }
     }
    });

$("#RTRButton").click(function(){
    $("#rtrDialog" ).dialog("open");
});


<!-- This form is used to capture the RTR related Dialogs -->

                        <div id="rtrDialog" title="Enter RTR Details">  
                        <form>  
                        <fieldset>    
                        <p><b>Enter Details for ?</b></p>
                        <input type="radio" name="entity" value="applicant"/>Applicant<br/>
                        <input type="radio" name="entity" value="co-app1"/>Co-Applicant 1<br/>
                        <input type="radio" name="entity" value="co-app2" />Co-Applicant 2<br/>
                        <input type="radio" name="entity" value="co-app3" />Co-Applicant 3<br/>
                        <input type="radio" name="entity" value="guarantor1" />Guarantor 1<br/>
                        <input type="radio" name="entity" value="guarantor2" />Guarantor 2<br/>
                        <input type="radio" name="entity" value="guarantor3" />Guarantor 3<br/> 
                        </fieldset>  
                        </form>
                        </div>

どうすればそれを行うことができますか??

jQuery-Ajaxのやり方をしなければなりませんか? または、これを行うより良いことはありますか

4

1 に答える 1

0
Use twitter bootstrap for opening the dialog box and perform your action..
http://getbootstrap.com/2.3.2/javascript.html#modals

check this..
Hope this will help ..
于 2013-11-08T05:59:24.100 に答える