Users Pricing

forum

home / developersection / forums / set multiple title on common modal popup window on button click in mvc

Set multiple title on common modal popup window on button click in mvc

Anonymous User 1562 13 Dec 2017

Hi Expert,

                Here is my code. i am open common modal popup on different button click. I want to set title of modal popup on button click.

<a class="btn btn-primary btn-sm pull-right openDialog" style="margin-top:-5px;margin-bottom:-3px" href="@Url.Action("Add")"><i class="fa fa-plus"></i></a>
$(document).on("click", ".openDialog", function (e) {


        e.preventDefault();

        var me = this;

        var option = { "backdrop": "static", keyboard: true };

        $.ajax({

            type: "GET",

            url: $(this).attr("href"),

            success: function (data) {

                $('#modelContent').html(data);

                $('#modelDialog').modal(option);

                $('#modelDialog').modal('show');

            }

        });

    });

Please give me some idea to achieve this task.


I am a content writter !


1 Answers