jQuery has an .after() method, and also an .insertAfter() method.
.after()
.insertAfter()
What\'s the difference between them? I think I can use .after()
They are inverses of each other. As explained in the jQuery documentation:
This:
$("p").insertAfter("#foo");
Is the same as this:
$("#foo").after("p");
And lastly, insertAfter returns all inserted elements, whereas .after() will return the context it is called on.