.replaceAll() Method

Syntax

$(content).replaceAll(selector)

Description

".replaceAll()" method is used to replace the selected elements with the specified content.
Note: The difference between replaceAll() and replaceWith() is that, replaceAll replaces the specified content for the all the selected element, where replaceWith replaces the specified content for the selected element only. The below example replaces the specified content for the selected elements.

Example Code

Result:


Welcome to Hscripts.com

Hscripts is praised as best free webmaster resources online, by our users.
Free website content that help to develop, build, promote and maintain a web site.



Ask Questions

Ask Question