'Invalid argument' when trying to using .animate() with variable in ie 7
Here is my function which works perfectly well in firefox and chrome:
- $('.estabInput').click(
function () {
//alert(originalPos);
dist =originalPos-(parseInt($(this).prev().css('width'))+7);
alert('distance');
var distO= {};
distO.left="'"+dist+"'";
$(this).prev().animate({'left':dist},'slow');
alert('animate');
$(this).prev().css('color','#000');
alert('colour');
}
)