Friday, July 21, 2017

Describe about jQuery after() and before() Methods.

jQuery after() and before() Methods

The jQuery after() method inserts content AFTER the selected HTML elements.
The jQuery before() method inserts content BEFORE the selected HTML elements.

Example

$("img").after("Some text after");

$("img").before("Some text before");