Javascript 通过imagemap链接加载引导3模式的内容

Javascript 通过imagemap链接加载引导3模式的内容,javascript,twitter-bootstrap,twitter-bootstrap-3,bootstrap-modal,imagemap,Javascript,Twitter Bootstrap,Twitter Bootstrap 3,Bootstrap Modal,Imagemap,我在一个页面上发布了许多引导模式。每个模式都包含一组显示在引导转盘中的图像。为了减少初始页面加载时间,我使用了一个来自answer的脚本,仅在打开模式时填充它。我对其进行了轻微修改,以便通过单独的PHP页面填充模式内容标记而不是模式正文标记: <script> // Fill modal with content from link href $("#myModal").on("show.bs.modal", function(e) {

我在一个页面上发布了许多引导模式。每个模式都包含一组显示在引导转盘中的图像。为了减少初始页面加载时间,我使用了一个来自answer的脚本,仅在打开模式时填充它。我对其进行了轻微修改,以便通过单独的PHP页面填充模式内容标记而不是模式正文标记:

<script>
// Fill modal with content from link href
$("#myModal").on("show.bs.modal", function(e) {
    var link = $(e.relatedTarget);
    $(this).find(".modal-content").load(link.attr("href"));
});
</script>

//使用链接href中的内容填充模式
$(“#myModal”)。on(“show.bs.modal”,函数(e){
var link=$(e.relatedTarget);
$(this.find(“.modal content”).load(link.attr(“href”));
});
这对于页面上的简单链接非常有用,如以下所示,当打开模式时,使用modal-content-example.php填充模式内容标记:

<a href="modal-content-example.php" data-remote="false" data-toggle="modal" data-target="#myModal" class="btn btn-default">Launch Modal</a>

但是,我还需要使用页面上的图像映射来启动相同的模态,但是JavaScript不适用于这些模态?下面的代码加载链接的PHP页面,替换现有页面,而不是使用PHP代码填充模态的模态内容标签:

<map name="MapName">
<area shape="circle" coords="825,406,60" href="modal-content-example.php" data-remote="false" data-toggle="modal" data-target="#myModal">
</map>

任何帮助,使它与图像地图以及正常的链接工作将非常感谢