Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks...
-
Upload
jward5519 -
Category
Technology
-
view
2.294 -
download
1
description
Transcript of Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks...
![Page 1: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/1.jpg)
Do Try This at HomeAjax Bookmarking, Cross-site Scripting
and Other Web 2.0 Browser Hacks
Brian Dillard, Ajax R&D, Pathfinder Development
1
![Page 2: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/2.jpg)
About this talk
1. Not too much code
2. The high-level stuff
3. The practical stuff
4. The uplifting finale
2
![Page 3: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/3.jpg)
Where we are
It’s a really exciting time to be a web developer. Cool stuff is coming out every single day.
3
![Page 4: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/4.jpg)
Where we are
... but it’s hard to get too excited about technologies
that aren’t yet ready for prime time. How best to participate?
4
![Page 5: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/5.jpg)
Where we areWalled gardens
vs.ecosystems
5
![Page 6: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/6.jpg)
Where we areOpen Web
vs.Closed Web
Jonathan Zittrain
6
![Page 7: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/7.jpg)
Where we areAjaxvs.
Flash/Flexvs.
Silverlight
7
![Page 8: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/8.jpg)
Where we arePrototype/Scriptaculous
vs.MooTools
vs.Dojo/Dijit/Dojox
vs.jQuery/jQuery UI
vs.YUI & Ext
8
![Page 9: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/9.jpg)
Where we areWeb standards
vs."embrace,
extend, then innovate"
9
![Page 10: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/10.jpg)
Where we areInternet Explorer 8
vs.Firefox 3
vs.Safari 3.1
vs.Opera 9.5
10
![Page 11: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/11.jpg)
To get a better future, not only do we need a return to 'the browser wars,' we need to applaud and use the hell out of 'non-standard' features until such time as there’s a standard to cover equivalent functionality. Non-standard features are the future, and suggesting that they are somehow 'bad' is to work against your own self-interest.
Alex Russell, President, Dojo Foundation
“11
![Page 12: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/12.jpg)
CSS masks!12
![Page 13: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/13.jpg)
CSS variables!13
![Page 14: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/14.jpg)
But ... Webkit? Safari?14
![Page 15: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/15.jpg)
What should I do?
15
![Page 16: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/16.jpg)
What's theright thing
to do?
What should I do?
16
![Page 17: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/17.jpg)
What's theright thing
to do?
How should Iinvest my time?
What should I do?
17
![Page 18: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/18.jpg)
The future liesin the tension
betweenemerging standards
and de facto standards
18
![Page 19: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/19.jpg)
Today's technologies grew in the wild
• xmlHttpRequest
• DOMContentLoaded
• Selectors API
• Canvas supplanted SVG
• HTML5 Ajax Navigation
• Microformats
19
![Page 20: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/20.jpg)
Tomorrow’s will grow ... in committees?
• HTML 5 in two dialects, HTML and XML
• XHTML 2
• ECMAScript 4 a.k.a. JavaScript 2
• CSS 3
• CSS Layout Module
• CSSOM
• DOM storage/client-side database storage
• Web Forms 2.0
20
![Page 21: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/21.jpg)
Draft specsare cool ...
21
![Page 22: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/22.jpg)
Draft specsare cool ...
but live implementations
are cooler.
22
![Page 23: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/23.jpg)
The Gears project started because a group of developers at Google were frustrated by the slow march of web browsers. Competition and standards were producing fantastic results, but it took a long time to get implementations on every browser. In some cases, we still don’t have compatible implementations, years after the standards were finalized.
Aaron Boodman, Gears Engineer
“23
![Page 24: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/24.jpg)
Who will play a role in determiningthe shape of tomorrow’s web?
• Proprietary runtimes set the pace for multimedia and native UI integration
• Standards bodies & browser vendors do their little dance
• Ajax libraries & browser plugins paper over the differences
24
![Page 25: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/25.jpg)
Who will play a role in determiningthe shape of tomorrow’s web?
So what about individual developers?
25
![Page 26: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/26.jpg)
Build cool stuff!
26
![Page 27: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/27.jpg)
Offline storage• Dojo Storage
• Flash LSOs (Local Shared Objects)
• IE userData
• Form field auto-save
• Google Gears
• DOM storage: sessionStorage/globalStorage
• Client database storage
27
![Page 28: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/28.jpg)
Ajax history and bookmarking
• Dojo Toolkit
• Various Ajax frameworks, including GWT
• Really Simple History
• dsHistory
• IE8 and Ajax Navigation
28
![Page 29: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/29.jpg)
Cross-site scripting
• Doom and gloom from Crockford
• But XSS !== malware
• FF3 cross-window messaging with HTML 5 postMessage API
• xssinterface - a library that uses postMessage, Gears or a cookie hack
29
![Page 30: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/30.jpg)
Other possibilities• CSSOM
• CSSOM View Module
• elementFromPoint for drag/drop
• Web Forms 2.0
• 2 projects in suspended animation
• Dust them off?
30
![Page 31: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/31.jpg)
Best practices?• If you’re doing something simple, try to use the
draft-standard API itself.
• If you’re building a higher-level abstraction, use draft standards when they’re available.
• If you’re going for the big hack, follow the conventions of successful libraries.
• If you don’t need to rely on a specific JavaScript framework, don’t.
• Make informed choices about joining the fray.
31
![Page 32: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/32.jpg)
Build plugins for popular frameworks.Solve a little problem well while looking to HTML 5.
How to be part of the conversation
32
![Page 33: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/33.jpg)
Participate actively in open-source projects.You don’t need to build a Gears module to use one.
How to be part of the conversation
33
![Page 34: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/34.jpg)
Get down and dirty with beta browsers.File bug reports. Join forums. Blog about it.
How to be part of the conversation
34
![Page 35: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/35.jpg)
Read and comment on draft specs
How to be part of the conversation
35
![Page 36: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/36.jpg)
Read and comment on draft specs... just not late at night.
How to be part of the conversation
36
![Page 37: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/37.jpg)
Vote with your feet.Use technologies whose philosophy you support.
How to be part of the conversation
37
![Page 38: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/38.jpg)
Become a beat reporter.
Tools for participating
38
![Page 39: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/39.jpg)
Research tools• RSS: NetNewsWire/FeedDemon/GReader
• Oversubscribe
• labs.pathf.com/ajax/web20expo/
• Or just bookmark trusted sites
• ajaxian.com
• quirksmode.org
• crockford.com
39
![Page 40: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/40.jpg)
Frequent browser vendor websites
Tools for participating
40
![Page 41: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/41.jpg)
Browser sites• Internet Explorer 8
• Readiness toolkit/developer forum
• Firefox 3
• Bug tracker
• Opera 9.5
• Bug tracker
• Safari 3
• Bug tracker
41
![Page 42: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/42.jpg)
Debuggers for everyone...not just Firefox & Firebug
Tools for participating
42
![Page 43: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/43.jpg)
Debuggers• Firefox
• Firebug
• Web developer toolbar
• Safari
• Develop menu
• Web Inspector
43
![Page 44: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/44.jpg)
Debuggers• IE8 Developer Tools
• Finally built in
• Opera Developer Console
• Just a bookmarklet
44
![Page 45: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/45.jpg)
Standards body websites
Tools for participating
45
![Page 46: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/46.jpg)
Standards bodies• WC3
• http://www.w3.org/
• WHATWG
• http://www.whatwg.org/
• ECMAScript
• http://www.ecmascript.org/
46
![Page 47: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/47.jpg)
Neither the CSS WG nor the HTML 5 WG nor, indeed, any W3C working group can define the future. They can only round off the sharp edges once the future becomes the past and that’s all we should ever expect of them. ... [T]he W3C cannot save us.
Alex Russell, President, Dojo Foundation
“47
![Page 48: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/48.jpg)
If you wait for Google, Prototype, the WC3 and
Adobe to solve your problems, then you’re
missing out.
48
![Page 49: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/49.jpg)
About me
• San Francisco: Reflect.com
• Chicago: United Airlines, Orbitz Worldwide
• Now: Pathfinder Development
• R&D: Playing with shiny new toys
• Blog: Agile Ajax (blogs.pathf.com/agileajax)
49
![Page 50: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/50.jpg)
Please rate me!50
![Page 51: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/51.jpg)
Please rate me!51
![Page 52: Do Try This At Home Ajax Bookmarking, Cross Site Scripting, And Other Web 2 0 Browser Hacks Presentation](https://reader038.fdocuments.net/reader038/viewer/2022110114/547e72d7b4af9f49338b4898/html5/thumbnails/52.jpg)
Please rate me!52