Button customization

Left button caption

The LeftButtonCaption property is used to specify the text of the Left Button. The default value is cancel.

  • html
  • <div style="text-align: center;">
            <input data-role="ejmbutton" type="button" data-ej-text="Open Dialog" data-ej-touchend="openAlertDialog" />
        </div>
        <div id="alertdialog" data-role="ejmdialog" data-ej-leftbuttoncaption="OK" data-ej-mode="confirm">
            <div>
                10% of battery remaining
            </div>
        </div>
  • js
  • function openAlertDialog(args) {
                $("#alertdialog").ejmDialog("open");
            }

    Right button caption

    The RightButtonCaption property specifies the text of the Right Button. The default value is continue.

  • html
  • <div style="text-align: center;">
            <input data-role="ejmbutton" type="button" data-ej-text="Open Dialog" data-ej-touchend="openAlertDialog" />
        </div>
        <div id="alertdialog" data-role="ejmdialog" data-ej-rightbuttoncaption="OK" data-ej-mode="confirm">
            <div>
                10% of battery remaining
            </div>
        </div>
  • js
  • function openAlertDialog(args) {
                $("#alertdialog").ejmDialog("open");
            }

    Show buttons

    The ShowButtons property is used to show the buttons in the Dialog box. The default value is true.

  • html
  • <div style="text-align: center;">
            <input data-role="ejmbutton" type="button" data-ej-text="Open Dialog" data-ej-touchend="openAlertDialog" />
        </div>
        <div id="alertdialog" data-role="ejmdialog" data-ej-showbuttons="false" data-ej-mode="confirm">
            <div>
                10% of battery remaining
            </div>
        </div>
  • js
  • function openAlertDialog(args) {
                $("#alertdialog").ejmDialog("open");
            }

    C:\Users\vigneshdr\Desktop\Mobile UG\Dialog\Emulator\8.png