【问题标题】:Identify the html content in the Iframe based on scroll基于滚动识别iframe中的html内容
【发布时间】:2015-07-13 19:29:28
【问题描述】:

我有一个包含 HTML 内容的 Iframe,每个行集都有一个 div。我想根据移动的滚动在 Iframe 中捕获视图中第一行的 div id。

【问题讨论】:

    标签: html iframe scroll


    【解决方案1】:

    您可以使用滚动偏移 (document.body.scrollTop) 结合 elementFromPoint(x,y) 来做一些事情

    document.elementFromPoint

    【讨论】:

      猜你喜欢
      • 2014-10-15
      • 1970-01-01
      • 2021-05-16
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-07-01
      • 2020-05-05
      相关资源
      最近更新 更多