jquery next with index

Hi,

There is a way to specify a parameter with next

$(this).next().next().next().next()

is there a way to specify how many next statements, something like that:

$(this).next(4) ????
LVL 1
joyacv2Asked:
Who is Participating?
 
leakim971Connect With a Mentor PluritechnicianCommented:
$(this).nextAll(":eq(4)")

Open in new window


Don't forget the first index is 0 (so 4 is 5th item)
0
 
joyacv2Author Commented:
works perfect!!! Thanks!!!!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.