Hi This will help you on this....
http://docs.jquery.com/Selectors/siblings#prevsiblings Thanks Ramesh On Fri, May 29, 2009 at 8:18 PM, Mauricio (Maujor) Samy Silva < css.mau...@gmail.com> wrote: > Well, I've tested here and works fine in IE6, IE7, Firefox 3.0.10, Opera > 9.64, Safari on Windows. > Have a closest look at your test case. > MaurĂcio > > -----Mensagem Original----- > *De:* Jakub Suder <jakub.su...@gmail.com> > *Para:* jQuery (English) <jquery-en@googlegroups.com> > *Enviada em:* sexta-feira, 29 de maio de 2009 11:32 > *Assunto:* [jQuery] Re: tilde (~) selector > > > On 29 Maj, 16:10, "Mauricio \(Maujor\) Samy Silva" > <css.mau...@gmail.com> wrote: > > It does. It returns b and d as expected! > > > > Try: > > $('p ~ p').css('color', 'red') > > and b and d will be red > > I've just noticed that it works in Safari (4 beta), but not in Firefox > (3)... this isn't normal, is it? :| > > JS > >