October 2013
Intermediate to advanced
1044 pages
24h 36m
English
CHAPTER 8
![]()
Manipulating Elements
In this chapter, I show you how to use jQuery manipulate elements, including how to get and set attributes, how to use the jQuery convenience methods for working with classes and CSS properties, and how to get and set HTML and text content. I also show you a nice feature that allows you to associate data with elements. Table 8-1 provides the summary for this chapter.
Table 8-1. Chapter Summary
| Problem | Solution | Listing |
|---|---|---|
| Get the value of an attribute from the first element in a jQuery object | Use the attr method | 1 |
| Get the value of an attribute from every element in a jQuery object | Use the each and |