Home:ALL Converter>jQuery animate from random position

jQuery animate from random position

Ask Time:2011-07-09T02:43:30         Author:webdev112

Json Formatter

I have a series of panels that I'd like to animate from random positions with jQuery.

Basically, I want a series of panels with random 'top', 'right', 'bottom', 'left' properties. In effect, I want some panels to slide in from the top, some from the left etc.

I've made a start, but am struggling to figure out how I'd go about getting the current elements css position property, i.e. top, bottom, left or right. Bear in mind I want the property, not the value.

Any ideas how I could achieve this?

Author:webdev112,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/6628955/jquery-animate-from-random-position
yy