Home > Article > Web Front-end > jQuery help filtering and finding children([expr])_jquery
children([expr])
Gets an element set containing all child elements of each element in the matched element set.
You can filter matching child elements through optional expressions. Note: parents() will find all ancestor elements, while children() will consider child elements but not all descendant elements.
Return value: jQuery
Parameters:
expr (String): (optional) Expression used to filter child elements.
Example:
Find every child element in a DIV.
HTML code:
Hello< /p>
And Again
Hello Again
And Again
Hello Again