Home › Forums › JavaScript › JQuery Animation
- This topic is empty.
-
AuthorPosts
-
September 24, 2009 at 3:39 pm #26228
tomwalters5678
MemberHi, I would like to recreate the effect you can see here: http://urbanmandesign.com/tests/animate.php using JQuery. I ask because it isn’t very easy on the browser using this method and I would like it to be a nice clean movement. I would then like to make it more complex for example adding rotation and I feel this could be better achieved with JQuery. So can this be done, and if so how?
Thanks
-Tom
September 24, 2009 at 8:21 pm #64660blue642
MemberSomething like this works….
Code:$(function (){$(“div”).animate({
bottom: “0px”,
right: “0px”
}, 3000 );
});The "bottom" and "right" parameters can be changed to whatever your destination should be.
The "3000" in the above example is miliseconds, so 3 seconds for it to travel to it’s destination…The html for this would need a div with position absolute.
Note, this is in essence, rapidly changing the CSS of the page, so sometimes it looks a littly sluggish/buggy. Also I don;t think rotation is supported, because css doesn’t natively support rotation (maybe some css3 stuff does, not too sure)
September 25, 2009 at 5:33 am #64692Rob MacKay
Participant"blue642" wrote:Note, this is in essence, rapidly changing the CSS of the page, so sometimes it looks a littly sluggish/buggy. Also I don;t think rotation is supported, because css doesn’t natively support rotation (maybe some css3 stuff does, not too sure)yea rotation is beginning to be supported – but yes, IE is probably going to hold back, or rotate in the opposite direction, or maybe just turn your site into a big "lol cat".
September 25, 2009 at 6:05 am #64693tomwalters5678
MemberThanks for your reply, I am going to use that code, and Rob tbh I stopped caring for IE and yeah, you are most likely right – but who cares?!
September 25, 2009 at 6:24 am #64694Rob MacKay
Participantwell unfortunately IE has a huge market share – so you do need to cater for IE users, mainly because most users wont know that the browser they use is a browser, they just think its the internet.
IE6 can go hang though lol
September 25, 2009 at 8:10 am #64697tomwalters5678
MemberOh yeah I totally agree, all I’m saying is I kow most of the visitors to my site won’t be using IE thereofre I will be focusing more on other, more up to date browsers.
BTW: The link is now dead
-
AuthorPosts
- The forum ‘JavaScript’ is closed to new topics and replies.