Chapter 3: Adding jQuery

In This Chapter

arrow.png Understanding what jQuery is

arrow.png Installing jQuery

arrow.png Adding jQuery to a page

arrow.png Adding HTML with jQuery

arrow.png Changing styles with jQuery

jQuery is a JavaScript library. Okay, that might not make much sense. What’s a JavaScript library? A JavaScript library is a collection of code that you use when you want to get access to additional functionality or make life easier. jQuery does both.

jQuery is simply JavaScript that you add to your web page to make writing JavaScript easier. You still use JavaScript with jQuery, so everything you learn in Chapter 2 is not wasted. However, there are certain things that jQuery does much better than plain old JavaScript. Working with web pages is one such thing. For instance, where you might use getElementById, jQuery has things called selectors that enable much more powerful ways to access things on a web page for JavaScript to use.

This chapter explains how to get started with jQuery and then shows some examples using ...

Get PHP, MySQL, JavaScript & HTML5 All-in-One For Dummies 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.