Increment css top property using jquery

前端 未结 5 1381
醉话见心
醉话见心 2020-12-24 02:03

I have the following div :

What is the best way to

5条回答
  •  抹茶落季
    2020-12-24 02:30

    var New = $("#new");
    
    function onEvent()
    {
       New.css("top", parseFloat(New.css("top")) + 10 + "px");
    }
    

    by adding the seconds parameter of to css your setting the property.

提交回复
热议问题