Book Image

Learning jQuery : Better Interaction Design and Web Development with Simple JavaScript Techniques

Book Image

Learning jQuery : Better Interaction Design and Web Development with Simple JavaScript Techniques

Overview of this book

Table of Contents (18 chapters)
Learning jQuery
Credits
About the Authors
About the Reviewers
Preface

Popular Plug-Ins


The jQuery website currently provides a long list of available plug-ins at http://jquery.com/Plugins, and plans are in the works to add features such as user ratings and comments to help visitors determine which are the most popular ones.

In this chapter we will explore three official plug-ins—so designated because of their mature code-base, usefulness, and adherence to a set of coding and documentation standards set by the jQuery project.

Dimensions

The Dimensions plug-in, co-authored by Paul Bakaus and Brandon Aaron, helps to bridge the gap between the CSS box model and developers’ need to accurately measure the height and width of elements in a document. It also measures with pixel accuracy the top and left offsets of elements, no matter where they are found on the page.

Height and Width

For measuring height and width, Dimensions provides three sets of methods:

  1. 1. .height() and .width()

  2. 2. .innerHeight() and .innerWidth()

  3. 3. .outerHeight() and .outerWidth()

The .height...