SitePoint jQuery, Novice to Ninja
What’s in This Book
By the end of this book, you’ll be able to take your static HTML and CSS web pagesand bring them to life with a bit of jQuery magic. You’ll learn how to select elements
on the page, move them around, remove them entirely, add new ones with Ajax,
animate them … in short, you’ll be able to bend HTML and CSS to your will! We
also cover the powerful functionality of the jQuery UI library, and investigate the
recently released jQuery Mobile framework.
This book comprises the following nine chapters and three appendices. Read them
in order from beginning to end to gain a complete understanding of the subject, or
skip around if you only need a refresher on a particular topic.
Chapter 1: Falling in Love with jQuery
Before we dive into learning all the ins and outs of jQuery, we’ll have a quicklook at why you’d want to use it in the first place: why it’s better than writing
your own JavaScript, and why it’s better than the other JavaScript libraries out
there. We’ll brush up on some CSS concepts that are key to understanding
jQuery, and briefly touch on the basic syntax required to call jQuery into action.
Chapter 2: Selecting, Decorating, and Enhancing
Ostensibly, jQuery’s most significant advantage over plain JavaScript is the easewith which it lets you select elements on the page to play with. We’ll start off
this chapter by teaching you how to use jQuery’s selectors to zero in on your
target elements, and then we’ll look at how you can use jQuery to alter those
elements’ CSS properties.
Chapter 3: Animating, Scrolling, and Resizing
jQuery excels at animation: whether you’d like to gently slide open a menu orsend a dialog whizzing across the screen, jQuery can help you out. In this
chapter, we’ll explore jQuery’s wide range of animation helpers, and put them
into practice by enhancing a few simple user interface components. We’ll also
have a quick look at some animation-like helpers for scrolling the page and
making elements resizable.
Chapter 4: Images and Slideshows
With the basics well and truly under our belts, we’ll turn to building some ofthe most common jQuery widgets out there: image galleries and slideshows.
We’ll learn how to build lightbox displays, scrolling thumbnail galleries and
cross-fading galleries, and even take a stab at an iPhoto-style flip-book.
Chapter 5: Menus, Tabs, Tooltips, and Panels
Now that we’re comfortable with building cool UI widgets with jQuery, we’lldive into some slightly more sophisticated controls: drop-down and accordionstyle
menus, tabbed interfaces, tooltips, and various types of content panels.
We’re really on a roll now: our sites are looking less and less like the brochurestyle
pages of the 1990s, and more and more like the Rich Internet Applications
of the 21st century!
Chapter 6: Construction, Ajax, and Interactivity
This is the one you’ve all been waiting for: Ajax! In order to make truly desktopstyleapplications on the Web, you need to be able to pass data back and forth
to and from the server without any of those pesky refreshes clearing your interface
from the screen—and that’s what Ajax is all about. jQuery includes a raft
of convenient methods for handling Ajax requests in a simple, cross-browser
manner, letting you leave work with a smile on your face. But before we get too
carried away, our code is growing more complex, so we’d better take a look at
some best practices for organizing it.
Chapter 7: Forms, Controls, and Dialogs
The bane of every designer, forms are nonetheless the cornerstone of any webapplication. In this chapter, we’ll learn what jQuery has to offer us in terms of
simplifying our form-related scripting.We’ll learn how to validate forms on the
fly, offer assistance to our users, and manipulate checkboxes, radio buttons,
and select lists with ease. Then we’ll have a look at some less conventional
ways of allowing a site’s users to interact with it: a variety of advanced controls
like date pickers, sliders, and drag and drop. We’ll round it off with a look at
modal dialogs in the post-popup world, as well as a few original nonmodal
notification styles. What a chapter!
Chapter 8: Lists, Trees, and Tables
No matter how “Web 2.0” your application may be, chances are you’ll still needto fall back on the everyday list, the humdrum tree, or even the oft-derided table
to present information to your users. This chapter will show how jQuery can
make even the boring stuff fun, as we’ll learn how to transform lists into dynamic,
sortable data, and tables into data grids with sophisticated functionality.
Chapter 9: Plugins, Themes, and Advanced Topics
jQuery is more than just cool DOM manipulation, easy Ajax requests, and funkyUI components. It has a wealth of functionality aimed at the more ninja-level
developer: a fantastic plugin architecture, a highly extensible and flexible core,
customizable events, and a whole lot more. In this chapter, we’ll cover the
jQuery UI theme system, which lets you easily tailor the appearance of jQuery
UI widgets to suit your site, and even make your own plugins skinnable with
themes.We’ll also take a look at using the brand new jQuery Mobile framework,
so that you can deploy your ninja skills on handheld devices.
Enregistrer un commentaire