1.jQuery append() method The jQuery append() method inserts content at the end of the selected element.
Example
$("p").append ("Some appended text.");
2.jQuery prepend() method jQuery prepend() method in the selected element Insert content at the beginning.
Example
$("p").prepend ("Some prepended text.");
3. after() and before() methods jQuery after() method after the selected element Insert content.
The jQuery before() method inserts content before the selected element.
Example
$("img").after ("Some text after");
$("img").before("Some text before");
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn