10. Building Web Page Content Dynamically

A critical part of using jQuery and JavaScript is the ability to dynamically build content to add to the page. This content may be form elements, images, lists, tables, or whatever type of element fits the need. Adding content to the page dynamically instead of requesting a new page from the server eliminates the server request time and allows you to build only those new pieces instead of everything.

The phrases in this chapter are designed to help you understand the methods of creating and adding content to the web page. They cover appending, prepending, and inserting elements of different types. Also covered is how to remove content from the web page.

Get jQuery and JavaScript Phrasebook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.