O'Reilly logo

jQuery in Action, Third Edition by Yehuda Katz Bear Bibeault and Aurelio De Rosa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Working with properties, attributes, and data

This chapter covers

  • Getting and setting element attributes
  • Working with element properties
  • Storing custom data on elements

Everyone who has approached software development for the first time has learned a very important lesson: even huge and complex software consists of a mix of elementary instructions. Summing numbers, counting items, and iterating over elements are just a few examples of these basic operations. In the same way, you can create a nice visual with jQuery by manipulating attributes, properties, classes, styles, and so on.

You can manipulate attributes and properties of elements with JavaScript’s native functions, but some tasks aren’t as easy as you’d like them to ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required