25% of what? specify an item you want the relative width to be, then replace '25%' with:
($(item).width()*.25) so you'd get $('#selectedFormat').animate({marginLeft:($(item).width()*.25)}, 500); not tested, but seems like it would work. Pat On Aug 1, 12:22 am, Kaitlyn2004 <[EMAIL PROTECTED]> wrote: > This works: > $('#selectedFormat').animate({marginLeft:50}, 500); > > this does't: > $('#selectedFormat').animate({marginLeft:25%}, 500); > nor does this: > $('#selectedFormat').animate({marginLeft:'25%'}, 500); > > how do I animate something on a percentage?