html marquee / lantern effect

Marquee are many ways in which the simplest is to use a Html code to implement, we need to place insert effect appears marquee "<marquee> scrolling text </ marquee>" statement, its effects are as follows:

Scrolling text

  Appropriate operation parameters <marquee> tag, can exhibit different effects, see the following a few examples:

  1, bouncing around ticker

Bouncing Marquee!

  The method is implemented on the tag and apply more IE several parameters produces a more abundant changes. Behavior = alternate set represents bidirectional movement, direction = left direction of motion to the left. The width of the marquee absolute pixel value may be used, for example, width = 200, etc. This value defines a ticker scrolling range. It should be noted that the effect is not visible at Netscape.

  Source Paste box:

<Marquee width = 400 behavior = alternate direction = left align = middle> bouncing Marquee! </ Marquee>

  2, run fast Marquee

Marquee run very fast! 

  As long as the <marquee> tag add back "scrollamount = 15" to modify the numerical parameters back to the limit speed = movement of text.

  3, marquees with hyperlinks

  Implemented method is very simple, the whole <marquee> </ marquee> statements contained in hyperlinks on the line, you look at the following code to clear. Pieces of content Of course, you can also include in the <marquee> </ marquee> respectively coupled with different links, this can be used to publish scrolling news ticker or do a site navigation.

  If you want to add marquee text color and replace it with a different font (the default is Times New Roman, for the body is necessary to add the code), long before the text with <FONT face = italics _GB2312 color = # ff0000 size = 3 > on the line, you can "face =" put behind your favorite fonts in "color =" put behind your favorite color words, in "size =" put behind for font size, font plus if you want the crude, coupled to the <STRONG>.

    Look at the results:  ! Marquee with hyperlinks point I try?       There is a too! Point I try ?

  The above code code the following effects:

<Marquee scrollamount = 2 width = 400> <a href= http://www.taobaojp5.tk> <FONT face = italics _GB2312 color = # ff0000 size = 3 > <STRONG> Marquee hyperlinked! point Let me try? </a> <a href = http: //954872988.qzone.qq.com/ ; there is a point I'll try it!? </ FONT> </ STRONG> </a> </ marquee>

  More than a few examples are <marquee> tag parameters of the application, you can use all of the following parameters listed in the table for your reference, but still have to remind you, <marquee> tag is only supported by IE, Netscape browser is using Oh, I can not see.

parameter Introduction Usage
behavior=scroll, slide, alternate Happy way: bypass loop, running only stopped once, back and forth motion
direction=left,right Happy direction: from left to right, right to left
loop=100 Happy times: 100 cycles, if not written by default has been circulating
width=100%,height=200 Happy range: 100% width, height 200 pixels
scrollamount=20 Happy rate: the number of bigger and faster
scrolldelay=500 Happy delay: the number of milliseconds, which may be implemented using a rolling leapfrogging
hspace=20,vspace=20 The size of the blank region between the other regions Happy
bgcolor=#00FFCC The background color of the Happy Valley area
face = italics _GB2312 Marquee text font
color=#ff0000 Marquee text color
size=3 Marquee text size
STRONG Marquee text bold

  You have seen, even though many <marquee> parameter, but after all, can not implement complex and customized marquees special effects, but also browser limitations, so our more cases will be implemented in JavaScript Marquee.

Guess you like

Origin www.cnblogs.com/matd/p/11671149.html