Refers to jQuery's append function, which allows you to insert content as the last child of the matched elements.
The
.append()
function inserts content, specified by the parameter, to the end of each element in the set of matched elements.
// added in version 1.0
$(selector).append( content [, content ] );
// added in version 1.4
$(selector).append( function );
Example usage:
Given this DOM:
<div>
<p>First paragraph</p>
</div>
The append function can be used to add a new p
tag to the end of it:
$('div').append('<p>New paragraph</p>');
For a result of:
<div>
<p>First paragraph</p>
<p>New paragraph</p>
</div>