The modal frame pop-up window brings out the contents of other div.

clipboard.png

clipboard.png

ajaxdiv

clipboard.png

post some code

{% extends "base.html" %}
{% block body %}

    <div class="wrapper wrapper-content animated fadeInRight">

        <div class="row">
            <div class="col-lg-12">
                <div class="ibox float-e-margins" style="z-index:9999;position: relative;">
                    <div class="ibox-title">
                        <h5>Custom responsive table </h5>
                    </div>

                    <div class="ibox-content">
                        <div class="row">
                            <select class="form-control m-b" name="group_name" id="group_id">
                                <option value=""></option>
                                {% for pro_i in pro_groups %}
                                    <option value="{{ pro_i.id }}">{{ pro_i.group_name }}</option>
                                {% endfor %}
                            </select>
                        </div>

                        <div class="row">
                            <table class="table">
                                <thead>
                                <tr>
                                    <th></th>
                                    <th></th>
                                    <th></th>
                                </tr>
                                </thead>
                                <tbody id="ossfile-tab-body">

                                </tbody>
                            </table>

                        </div>


                    </div>

                </div>


            </div>
        </div>
    </div>

    <!-- Modal -->
    <div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button>
                    <h4 class="modal-title" id="myModalLabel"></h4>
                </div>
                <div class="modal-body" id="modal_userId"></div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal"></button>
                    <button type="button" id="modal_user" class="btn btn-primary"></button>
                </div>
            </div><!-- /.modal-content -->
        </div><!-- /.modal -->
    </div>



{% endblock %}

{% block comm_js %}
    <script type="text/javascript">

        $("-sharpgroup_id").change(function () {
            var group_id = $("-sharpgroup_id").val();
            $.ajax({
                data: {"group_id": group_id, csrfmiddlewaretoken: "{{ csrf_token }}"},
                type: "POST",
                url: "/pro1/gamebuild/" + group_id + "/",
                success: function (data) {
                    var json_data = JSON.parse(data);
                    var content = "";
                    $.each(json_data, function (i, item) {
                        content += " <tr> <td>" + item.groupname + "</td> " +
                            "<td>" + item.game_name + "</td>  " +
                            "<td><div class="font-bold">" +
                            "<button class="btn btn-info " id= \"+ item.id +\"version_value="trunk" type="button" onclick="Trunk(this)">" +
                            "<i class="fa fa-paste"></i> </button>" +
                            "<button class="btn btn-danger" id= "+ item.id +"version_value="branch" type="button" onclick="Branch(this)">" +
                            "<i class="fa fa-trash"></i> <span class="bold"></span></button>" +
                            "</div></td></tr>"
                    });
                    $("-sharpossfile-tab-body").html(content)
                }

            })
        });


        function Trunk(obj) {
            var version_value = $(obj).attr("version_value");
            var id = $(obj).attr("id");
            {-sharpalert(version_value);-sharp}
            $("-sharpmyModalLabel").html("");
            $("-sharpmodal_userId").html(": " + version_value + " ?");
            $("-sharpmyModal").modal("show");
        }


    </script>
{% endblock %}
Nov.15,2021

check css, to make sure there is something wrong with the z-index that is not the "real-time compilation log"
. In addition, clean the content of the page bit by bit until only modal and the faulty div
check that each dom is closed correctly, and don't accidentally bring other div packages in. The


code did not take a closer look.
generally speaking, the structure is written like this, and the modal boxes are uniformly placed in a modal layer container to provide the background color of the back translucent mask and to proxy the click events of all dynamic modal boxes. The show / hide control usually has one on the modal box, and then there is also one on the common modal layer. Display several of these at one time, usually when dealing with show / hide logic, only focus on dealing with the modal layer, forget to deal with the modal box itself; or the modal box is all selected incorrectly, followed by a toggleClass or show, which are common problems.

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b36f66-2c04b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b36f66-2c04b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?