Documente Academic
Documente Profesional
Documente Cultură
JavaScript
behavior oriented JS with
graceful degradation
progressive enhancement
3
• create a page that works with
and without javascript
4
Progressive
Enhancement
5
• graceful degradation is good
but...
6
how?
7
• register event handlers
programmatically
• use CSS selectors to select the
elements to register
• keep things separate
8
V from MVC
9
• Structure: HTML
• Presentation: CSS
10
• Structure: HTML
• Presentation: CSS
• Behavior: JavaScript
Keep the layers separate
11
structure:
12
presentation:
13
behavior:
14
JQuery + livequery
15
Prototype + LowPro
16
resources
• http://prototypejs.org
• http://danwebb.net/lowpro
• http://lowpro.stikipad.com/
• http://groups.google.co.uk/group/low-pro?hl=en
• http://jquery.com/
• http://brandonaaron.net/docs/livequery/
• http://railsontherun.com
17