开发者

Blinks or flash bgcolor

开发者 https://www.devze.com 2023-01-07 16:20 出处:网络
I have there is a table showing the last 10 news. But when I want to put any new command to the ne开发者_运维百科ws appears in the td blinks or flash bgcolor.If you\'re using jQuery, you can achieve t

I have there is a table showing the last 10 news. But when I want to put any new command to the ne开发者_运维百科ws appears in the td blinks or flash bgcolor.


If you're using jQuery, you can achieve this effect with animate like this:

$(".my-new-tr td").css("background:#ffff00")             // make the background yellow
                  .animate({ "background": "#ffffff" })  // fade to white
                  .parent().removeClass("my-new-tr");

This assumes your newly added row will be given the class my-new-tr when created. This class will be removed after the effect.

0

精彩评论

暂无评论...
验证码 换一张
取 消