CUSTOM BUTTON OPEN POPUP

CUSTOM BUTTON OPEN POPUP

luciodicunzololuciodicunzolo Posts: 2Questions: 1Answers: 0

Hi all, trying to make a button that open new popup.
Trying:

{
Extends: "ajax",
text: "Nuovo PDF",
fnClick: function ( nButton, oConfig, oFlash )
{
window.open('pdf_test.php','mywindow','width=400,height=200,left=0,top=100,screenX=0,screenY=100');
}
}

Doesnt work....any help?
Thx

Answers

  • luciodicunzololuciodicunzolo Posts: 2Questions: 1Answers: 0

    Here it works...

                buttons: [
    
                    {
                 Extends: "ajax",
                 text: "Nuovo PDF",
                  action: function ( e, dt, node, config ) {
                window.open('pdf_conv_bon.php?sumdare=<?php echo $sumdare?>&sumavere=<?php echo $sumavere?>','mywindow','width=1200,height=1200,left=200,top=200,screenX=0,screenY=100');
                }
    
  • allanallan Posts: 63,161Questions: 1Answers: 10,406 Site admin

    Thanks for posting back - you are correct, the buttons.buttons.action option is how to define a custom action in Buttons.

    Allan

This discussion has been closed.