jQuery: Common DOM manipulation methods

This entry is part 14 of 33 in the series jQuery Tutorial

We look at some of the more commonly used DOM manipulation methods such as .attr() and .appendTo().

MethodDescription
.appendTo()Insert every element in the set of matched elements to the end of the target.
.attr()Get the value of an attribute for the first element in the set of matched elements or set one or more attributes for every matched element.
.addClass()Adds the specified class(es) to each of the set of matched elements.
.after()Insert content, specified by the parameter, after each element in the set of matched elements.
.append()Insert every element in the set of matched elements to the end of the target.
.before()Insert content, specified by the parameter, before each element in the set of matched elements.
.clone()Create a deep copy of the set of matched elements.
.css()Get the value of a style property for the first element in the set of matched elements or set one or more CSS properties for every matched element.
Series Navigation<< jQuery: 2 DOM manipulation examples
jQuery: removeClass >>