Thanks so much!
I don't really understand the logic behind it. The .css() set the
value to 200px but why I need to use the same value in anumate
(200px) ? By the way, .css has a bigger priority than animate?

Thanks again! I appreciate your help!

On Jul 11, 3:51 am, Karl Swedberg <k...@englishrules.com> wrote:
> You could chain a .css() to it. Set the x axis first with .css() and  
> then the y axis with .animate() :
>
> $(this)
>    .css({backgroundPosition: '200px 0'})
>    .animate({backgroundPosition:"(200px -50px)"}, {duration: 600})
>
> --Karl
>
> ____________
> Karl Swedbergwww.englishrules.comwww.learningjquery.com
>
> On Jul 10, 2009, at 6:57 PM, yo2lux wrote:
>
>
>
> > Hi,
> > The background position plugin by Alexander Farkas rocks!!
> > But I have a question.. Is possible to remove the animation for the X-
> > axis ? For example:
>
> > $(this).animate({backgroundPosition:"(200px -50px)"}, {duration: 600})
>
> > I don't want to animate the X-axis. I don't need 1 2 3 4 .... 200px..
> > I want to achieve 200px without any incrementation.
>
> > On the other side I need the animation on Y-axis.. I want to increment
> > to -50, something like -0 -1 -2 -3 -4 ..... etc...
>
> > I appreciate if someone try to help! Thanks!

Reply via email to