【问题标题】:Vertical Marquee remove space垂直选取框删除空间
【发布时间】:2015-12-22 10:27:24
【问题描述】:

我想在我的页面<div> 中包含一些垂直选取框文本,以便自动滚动内容。

我发现以下代码很有用;

<marquee behavior="scroll" direction="up" height="250" scrollamount="2" scrolldelay="10" onmouseover="this.stop()" onmouseout="this.start()">
content goes here<br>
content goes here<br>
content goes here<br>
content goes here
</marquee>

但它在内容之后添加了一个空格。只有在整个文本向上滚动(类似于重新启动)后才会出现内容。我怎样才能避免(或删除)这个空白?

我在 Stack Overflow 中找到了 here,并且注意到了 cloneNode()。我不知道如何实现。

*注意:高度属性不相关。它与父&lt;div&gt;具有相同的高度

【问题讨论】:

    标签: html marquee clonenode


    【解决方案1】:
    1. &lt;marquee&gt; 元素不符合 HTML 标准,不应使用...但这是一个完全不同的论点。
    2. 就其性质而言,该元素将在内容中一直滚动,然后再次循环。
    3. 您可以使用 javascript based solutions 来做同样的事情,但会持续循环。

    【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-10-01
    • 1970-01-01
    • 1970-01-01
    • 2021-03-19
    • 2021-04-24
    相关资源
    最近更新 更多