Prototype and script.aculo.us
| Auteur(s): | Christophe Porteneuve |
|---|---|
| Uitgever: | Pragmatic Bookshelf |
| Web: | http://www.oreilly.com/catalog/9781934356012/ |
| Prijsindicatie: | EUR. 32,99 |
| Verschijningsdatum: | December 2007 |
| Aantal pagina's: | 436 |
| ISBN: | 9781934356012 |
Omschrijving
Met de komst van web 2.0 wordt meer en meer aandacht besteed aan de ervaringen van de gebruiker, wat het tegelijkertijd moeilijker maakt voor de scripter om aan alle standaarden te voldoen (denk aan Javascript, DOM, CSS, XML etc.). Bovendien wordt het lastiger om alle verschillen tussen de diverse browsers op te heffen (alhoewel dat met de komst van IE8.0 hopelijk weer wat makkelijker gaat worden).
Prototype en script.aculo.us nemen je veel werk uit handen door die verschillen op te heffen en de (moeilijkheid van) implementatie van veel voorkomende features tot een minimum te beperken.
Inhoud
Preface
1 Introduction
1.1 It’s About Time 1.2 What’s in This Book, and How Is It Organized? 1.3 Acknowledgments
I Prototype
2 Discovering Prototype
2.1 What Is Prototype, and What Is It Not? 2.2 Using Prototype in Our Project 2.3 What Does Our JavaScript Look Like When Using Prototype? 2.4 Prototype Jargon and Concepts 2.5 What Are Prototypes Anyway? 2.6 Running Prototype Code Samples in This Book
3 Quick Help with the Dollars
3.1 Shortcuts Should Be Short 3.2 Quick Fetching of Smart Elements with $ 3.3 $w, Because Array Literals Are Boring 3.4 $$ Searches with Style 3.5 $A, the Collection Unifier 3.6 $F Is a Field Expert 3.7 $H Makes a Hash of Things 3.8 Handling Ranges with $R
4 Regular JavaScript on Steroids
4.1 Generic Object Manipulation 4.2 Proper Function Binding 4.3 Your Functions Actually Know More Tricks 4.4 Numbers 4.5 Strings 4.6 Arrays 4.7 Full-Spectrum JSON Support
5 Advanced Collections with Enumerable
5.1 The Core Method: Iterating with each 5.2 Getting General Infor mation About Our Collection 5.3 Finding Elements and Applying Filters 5.4 Grouping Elements and Pasting Collections Together 5.5 Computing a Derived Collection or Value 5.6 Order Now: Getting Extreme Values and Using Custom Sorts 5.7 Tur ning Our Collection into an Array or Debugging String 5.8 Enumerable Is Actually a Module
6 Unified Event Handling
6.1 Event 6.2 The Events Hall of Fame 6.3 Reacting to For m-Related Content Changes
7 Playing with the DOM Is Finally Fun!
7.1 Extending DOM Elements 7.2 Element, Your New Best Friend 7.3 Selector 7.4 Debugging Our DOM-Related Code
8 Form Management
8.1 Toward a Better User Inter face 8.2 Looking at For m Fields 8.3 Submitting For ms Through Ajax 8.4 Keeping an Eye on For ms and Fields
9 Ajax Has Never Been So Easy
9.1 Before We Start 9.2 Hitting the Road: Ajax.Request 9.3 Streamlining: Ajax.Updater 9.4 Polling: Ajax.PeriodicalUpdater 9.5 Monitoring Ajax Activity: Ajax.Responders 9.6 Debugging Ajax 9.7 Ajax Considered Harmful? Thinking About Accessibility and Ergonomy
10 More Useful Helper Objects
10.1 Storing Values in a Hash 10.2 Expressing Ranges of... Well, Anything You Want! 10.3 Periodical Execution Without Risk of Reentrance 10.4 Templating Made Easy 10.5 Examining the Current Browser and Prototype Library
11 Performance Considerations
11.1 Element Extension and the $ Function 11.2 Iterations vs. Regular Loops 11.3 Obsolete Event Handlers 11.4 Recent Speed Boosts You Should Know About 11.5 Small Is Beautiful
12 Wrapping Up
12.1 Building a Fancy Task List 12.2 Laying the Groundwork 12.3 It Takes Only 40 Lines: The JavaScript Code
II script.aculo.us
13 Discovering script.aculo.us
13.1 The Modules of script.aculo.us 13.2 Using script.aculo.us in Your Pages
14 Visual Effects
14.1 What Are Those Effects, and Why Should We Use Them? 14.2 Core Effects 14.3 Diving into Effects 14.4 Combined Effects 14.5 Unlocking the Cool Factor: Effect Queues 14.6 Effect Helpers 14.7 How to Create Our Own Effects
15 Drag and Drop
15.1 Dragging Stuff Around 15.2 Controlling How It Starts, Where It Goes, & How It Ends 15.3 Ghosting 15.4 Dragging and Scrolling 15.5 Monitoring Drags 15.6 Dropping Stuff 15.7 Customizing Drop Behavior 15.8 Sorting with Drag and Drop 15.9 Common Pitfalls
16 Autocompletion
16.1 The Basics 16.2 Local Autocompletion 16.3 Getting Ajaxy 16.4 Using Rich-Markup Choices 16.5 Autocompleting Multiple Values in One Field 16.6 Reacting to Completion with Callbacks
17 Building DOM Fragments the Easy Way: Builder
17.1 Building Explicitly 17.2 Using an (X)HTML Representation
18 In-Place Editing
18.1 What’s In-Place Editing Exactly? 18.2 A Simple Example 18.3 How Can We Tweak the Ajax Persistence? 18.4 Customizing the Appearance 18.5 Dealing with Multiple Lines 18.6 Editing Alter native Text 18.7 Disabling In-Place Editing 18.8 Of fering a List of Values Instead of Text Typing
19 Sliders
19.1 Creating a Simple Slider 19.2 Customizing the Basics 19.3 Restricting Range or Allowed Values 19.4 Tweaking an Existing Slider and Adding Controls 19.5 Defining Multiple Values
20 Sound Without Flash
20.1 Where Does It Work? 20.2 How Do We Play Sounds? 20.3 Playing Multiple Sounds on Multiple Tracks
A Extending and Contributing
A.1 Building Over: Classes, Inheritance, and DOM Extension A.2 Contributing!
B Further Reading
B.1 Official Websites B.2 Useful Blogs by Prototype Core Members B.3 JavaScript Masters B.4 Community and New Sites Around Ajax B.5 ECMAScript Intimacy B.6 Bibliography
C Installing and Using Ruby
C.1 On Windows C.2 On Linux C.3 On Mac OS X C.4 Running a Ruby Script C.5 “But I Don’t Know a Thing About Ruby!”
Index
Recensies
Te vinden op o.a.: http://www.oreilly.com/catalog/9781934356012/
Verkooppunten
PFZ topic(s) over dit boek
Meningen
Prototype and script.aculo.us (You Never Knew JavaScript Could Do This!) is ten eerste zeker niet geschikt voor de beginnende webprogrammeur; er wordt flink wat ervaring vereist (uiteraard voornamelijk met Javascript). Het is echter wel een érg uitgebreid boek en ikzelf heb de indruk dat alle snufjes die tegenwoordig gebruikt worden (denk aan auto-aanvullen, sorteren, slepen met div's) in dit boek diepgaand behandeld worden. Het is daarmee meer een soort uitgebreid en leesbaar (referentie-)handboek voor beide bibliotheken geworden dan echt een studieboek.
Christophe Porteneuve gebruikt relatief weinig voorbeeldcode in zijn boek wat ikzelf een prettige ervaring vond. Aan de balans tussen tekst en code zouden veel programmeerboeken nog een voorbeeld kunnen nemen. Het Engels is overigens van een vrij hoog niveau - misschien iets om rekening mee te houden bij een eventuele aanschaf.





