Home  >  Article  >  Web Front-end  >  JavaScript dynamically changes page elements

JavaScript dynamically changes page elements

高洛峰
高洛峰Original
2016-11-25 09:28:38901browse

You can dynamically change elements in HTML through JavaScript

Add elements to HTML

First you need to create a tag, then add the corresponding content to the tag, and then add the created tag to the corresponding location.





Test document




This is the first paragraph


This is the second paragraph







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