jQuery From The Ground UpKevin Griffin
About MeKevin GriffinChesapeake, VAASPInsiderINETA Mentor for VirginiaLeader of the Hampton Roads .NET Users Grouphttp://www.kevgriffin.comTwitter: 1kevgriffEmail: kevin@kevgriffin.com
Mid-Atlantic Developer’s Grouphttp://midatlanticdevs.groups.live.comMailing list for developers based in the Mid-Atlantic regionKeep up to date with what’s going on outside your groupAsk questionsPost jobsNetwork!
Before We BeginYou’re not tied to your chairCode camps are about getting the best experience possibleQuestionsAsk them, anytime.
AgendaWhat Is jQueryGetting jQuerySetting Up jQueryUsing jQueryjQuery UIPluginsDemos! Demos! Demos!
What Is jQuery?JavaScript libraryPowerful document traversalEvent handlingAnimationsAJAXMakes JavaScript not SUCK!
Document Transversal?Where do elements exist on the page?How quickly can we access them?
Who Use’s jQuery?GoogleNetflixDellBank of AmericaMajor League BaseballDiggNBCCBS
Browser CompatibilityInternet Explorer 6.0+Firefox 2.0 +Safari 3.0+Opera 9.0+Chrome
Getting jQuery
Production vs. DevelopmentProductionMinifiedQuick to downloadImpossible to read and debugDevelopmentCommentedFormattedLarge file
Deployment TipsDon’t host jQuery yourself!http://code.google.com/apis/ajaxlibs/documentation/Numerous website use the Google version.Possibly already cached on a person’s machine.Both production and development versions are available.
A note about jQuery documentationIt’s awesome!http://docs.jquery.comEasy to navigate and searchExamples on every topicTutorials, references, and FAQs
VS2008 Intellisensehttp://docs.jquery.com/Downloading_jQueryAdd the *-vsdoc.js file to your solutionEnjoy full jQueryIntellisense!
DemoSetting up jQuery
Setting Up jQuery
jQuery Syntax$(selector).function()$ or jQueryjQuery objectselectorreference to an element on the pageFunctionAny jQuery supported method or plugin.
What is a selector?Think CSS!jQuery has a built in DOM transversal engine.$(selector) returns a list of elements on the page that match the “selector”.Example: $(“input”) will return a list of ALL input elements on the page.
DemoSelectors
$(document).ready()Fixes problems based on window.onload as a way of handling events when page is loaded.Window.onload fires only after all HTML and images have been downloaded.$(document).ready() fires as soon as all markup has been downloaded.
DemoA Better Contact Form: Putting jQuery to Work
jQuery UIhttp://jqueryui.com/Several comment UI widgets and visual effects.Compatible with several browsers, including IE 6.0.
DemojQuery UI
3rd Party PluginsHundreds of plugins availableDon’t re-invent the wheel!AJAX, Animation, Effects, Browser Tweaks, Drag and Drop, Forms, Layouts, Media, Menus, Navigation, Tables, UI, Widgets, etc…http://plugins.jquery.com
Questions?http://www.kevgriffin.comTwitter: 1kevgriffEmail: kevin@kevgriffin.com

jQuery From the Ground Up