i m having a jquery animate function to animate a list which is specified using
$li = $("ol#update > li");
the animate function
function animate_li()
{
$li.filter(':first')
.animate({
height: 'show',
opacity: 'show'
}, 250, function(){
animate_li();
});
$li = $li.not(':first');
}
now i want to parameterize the animate_li function which i have done as:
function sp_animate_li(sp)
{
console.log ( $li );
function animate_li()
{
$li.filter(':first')
.animate({
height: 'show',
opacity: 'show'
}, sp, function(){
animate_li();
});
$li = $li.not(':first');
}
}
but now i cannot get any animation using the call
sp_animate_li(100);
Any help
thanks