'thisAnchorMargin is an float. why doesn't this work? if i just put a numerical value in there and don't concatenate the % (e.g. top: 50%) it works. is this not a valid unit type to animate in jquery?
$('.mar开发者_C百科kerContainer').stop().animate({
top: thisAnchorMargin + '%'
}, {
duration:scrollSpeedGlobal,
queue:false
});
I tried it with several different floats (concatenating the '%') and it works just fine, at least in Chrome/Mac. http://jsfiddle.net/9d6ck/
精彩评论