jQuery slice() Method

Last Updated Jul 21, 2015, 12:00:06 PM





jQuery slice() Method

jQuery slice() method selects a subset of elements based on its index. A subset is a set that is a part of a larger set. .

Syntax

Look at the below jquery slice() method example code as shown below.

Example

It will select all the paragraph p elements from the index 3 and highilight its background as Yellow color



Try It Now

Other Advanced jQuery Traversing Methods you might want to learn
jQuery Traversal Reference

jQuery Basic Traversing

jQuery Traversal Filters

jQuery Traversing Methods


Sources and Credits

The content and methods in the tutorial has been referred and updated with jQuery API and The jQuery Foundation

Last Updated Jul 21, 2015, 12:00:06 PM