I am trying to create a JQuery plug in to slide some images from right to left.
I tried to search for a plug in but i thought i’d create it myself.
What I have:
– several DIV elements like this:
<div class="footer_image_div project">
</div>
- i thought if i retrieve all the positions of the projects and animate them to 260 to the left it’d worked
I tried
$(function(){
$('.project').each(function() {
alert('a');
var elm = $(this);
elm.find(".project").animate({}, 500, function(){
var pos = elm.find(".project").position();
alert(pos.top);
});
});
});
I did try offset aswell both do return NULL.
What should i do?
Where should i look? I am confused
1 Answer