首页 > 解决方案 > 从同一网页调用不同的模型图像

问题描述

我的起点是:如何 - 模态图像 w3schools.com

https://www.w3schools.com/howto/howto_css_modal_images.asp

我想从一个网页调用许多不同的模式。TIA 对不起,我是个无知的菜鸟。

找到这个: https ://blr.design/blog/multiple-modals/ 和这个: https ://codepen.io/JackZelig/pen/VPdQXJ

 <!-- Trigger the Modal -->
<img id="myImg" src="img_snow.jpg" alt="Snow" style="width:100%;max-width:300px">

<!-- The Modal -->
<div id="myModal" class="modal">

  <!-- The Close Button -->
  <span class="close">&times;</span>

  <!-- Modal Content (The Image) -->
  <img class="modal-content" id="img01">

  <!-- Modal Caption (Image Text) -->
  <div id="caption"></div>
</div> ```

标签: javascripthtmlcss

解决方案


推荐阅读