the last demo was too simple. It is estimated that everyone is not interested in it. This time, I will not play a new window to see the effect. Let's take a look. There seems to be some conflict with the garden style on the page [no problem in Firefox]. Let's take a look. We recommend that you directly go to the demo. Haha demo download. A new demo with a button is added.
fixed the added content:
1. fixed the problem that multiple settimeouts are triggered when a continuous mouseout occurs.
2. Add the first row and Click Previous to jump to the last record.
3. Added scrollamount and scrolldelay attributes to [attributes similar to Marquee].
4. A direction attribute is added, which only enables up and down. If you are interested, you can implement left and right.
5. change the btnprevious and btnnext parameters to optional parameters.
6. Found the functions that can be used as marquee.
latest product name: latest product 1
Description: latest product 1 has arrived.
price: ¥999.99 name: latest product 2
Description: latest product 2 arrived.
price: ¥999.99 name: latest product 3
Description: latest product 3 has arrived.
price: ¥999.99 name: latest product 4
Description: latest product 4 has arrived.
price: $999.99 scroll up
var scrollup = new scrolltext ("listcontent");
scrollup. lineheight = 60;
scrollup. amount = 4;
scrollup. start ();
Latest Product Name: latest product 1
Description: The latest product 1 has arrived.
Price: ¥999.99 name: latest product 2
Description: The latest product 2 has arrived.
Price: ¥999.99 name: latest product 3
Description: The latest product 3 has arrived.
Price: ¥999.99 name: latest product 4
Description: Product 4 has arrived.
Price: ¥999.99 can also be used as marquee
VaR marquee = new scrolltext ("listmarquee ");
Marquee. lineheight = 60;
Marquee. Amount = 1;
Marquee. Timeout = 30;
Marquee. Delay = 30;
Marquee. Start ();
Latest Product Name: latest product 1
Description: The latest product 1 has arrived.
Price: ¥999.99 name: latest product 2
Description: The latest product 2 has arrived.
Price: ¥999.99 name: latest product 3
Description: The latest product 3 has arrived.
Price: ¥999.99 name: latest product 4
Description: Product 4 has arrived.
Price: $999.99 scroll down
VaR scrolldown = new scrolltext ("listcontent ");
Scrolldown. lineheight = 60;
Scrolldown. Amount = 4;
Scrolldown. Direction = "down ";
Scrolldown. Start ();
latest product name: latest product 1
Description: latest product 1 has arrived.
price: ¥999.99 name: latest product 2
Description: latest product 2 arrived.
price: ¥999.99 name: latest product 3
Description: latest product 3 has arrived.
price: ¥999.99 name: latest product 4
Description: latest product 4 has arrived.
price: the effect of adding a button next to ¥999.99
var scrolldown = new scrolltext ("listwithbtn", "scrollpre", "scrollnext");
scrolldown. lineheight = 60;
scrolldown. amount = 4;
scrolldown. start ();