2013-02-10 67 views
3

我是HTML中的新手。我正在使用<marquee>標記。更改腳步和方向<marquee>

有沒有辦法將文字移動的方向從右向左改爲其他方向?

另外,我可以改變這些選框運行的速度嗎?

+0

請看這裏http://www.plus2net.com/html_tutorial/html_marquee_direction.php – Pandian 2013-02-10 18:29:40

回答

3

您可以使用標籤創建滾動字幕(即滾動文字或滾動圖像)。它可以完全定製。在你有興趣修改滾動文本的方向和速度,這可能通過添加一些屬性。

例如,一個示例HTML代碼:

<marquee behavior="scroll" direction="left" scrollamount="1">Pace-slow</marquee> 

這裏屬性方向可以根據滾動的方向值等向左,向上,向右等和滾動量可以控制速度,更越快。

1

<!-- Scroll Amount --> 
 
<marquee scrollamount="50"> This is a marquee with scrollamount 50 </marquee> 
 
<marquee scrollamount="5"> This is a marquee with scrollamount 5 </marquee>

<!-- Scroll Delay --> 
 
<marquee scrolldelay="50">This is a marquee with scrolldelay 50</marquee> 
 
<marquee scrolldelay="100">This is a marquee with scrolldelay 100</marquee>

<!-- mouse over or click events --> 
 
<marquee onmouseover="this.stop()" onmouseout="this.start()">This marquee will stop on mouseover.</marquee> 
 
<marquee onclick="this.stop()">This marquee will stop on mouseclick. </marquee>

附加參考: enter link description hereenter link description here