Suddenly, everyone’s talking about HTML5, and ready or not, you need to get acquainted with this powerful new development in web and application design. Some of its new features are already being implemented by existing browsers, and much more is around the corner. Written by developers who have been using the new language for the past year in their work, this book shows you how to start adapting the language now to realize its benefits on today’s browsers. Rather than being just an academic investigation, it concentrates on the practical—the problems HTML5 can solve for you right away. By following the book’s hands-on HTML5 code examples you’ll learn:
- new semantics and structures to help your site become richer and more accessible
- how to apply the most important JavaScript APIs that are already implemented
- the uses of native multimedia for video and audio
- techniques for drawing lines, fills, gradients, images and text with canvas
- how to build more intelligent web forms
- implementation of new storage options and web databases
- how geolocation works with HTML5 in both web and mobile applications
All the code from this book (and more) is available at www.introducinghtml5.com. ******** There appear to be intermittent problems with the first printing of Introducing HTML5. If you have one of these copies, please email us at
[email protected] with a copy of your receipt (from any reseller), and we'll either provide access to the eBook or send you another copy of the print book -- whichever you prefer. If you’d like the eBook we can add that to your Peachpit.com account. You can set up a free account at www.peachpit.com/join <
http://www.peachpit.com/join>. Thanks so much for your understanding!
Author(s): Bruce Lawson, Remy Sharp
Series: Voices That Matter
Edition: 1
Publisher: New Riders Press
Year: 2010
Language: English
Pages: 241
Tags: Библиотека;Компьютерная литература;HTML / CSS / JavaScript;HTML5 / CSS3;
Contents......Page 6
Introduction......Page 10
CHAPTER 1 Main structure......Page 18
The ......Page 19
Using new HTML5 structural elements......Page 23
Styling HTML5 with CSS......Page 27
When to use the new HTML5 structural elements......Page 30
Summary......Page 38
CHAPTER 2 Text......Page 40
Structuring main content areas......Page 41
Adding blogposts and comments......Page 46
Working with HTML5 outlines......Page 47
Understanding WAI-ARIA......Page 65
Even more new structures!......Page 68
Redefined elements......Page 73
Global attributes......Page 78
Features not covered in this book......Page 81
Summary......Page 83
CHAPTER 3 Forms......Page 84
New input types......Page 85
New attributes......Page 91
Putting all this together......Page 96
Backwards compatibility with legacy browsers......Page 99
Styling new formelds and error messages......Page 100
Overriding browser defaults......Page 101
Using JavaScript for DIY validation......Page 102
Avoiding validation......Page 103
Summary......Page 106
CHAPTER 4 Video and Audio......Page 108
Native multimedia: why, what, and how?......Page 109
Codecs—the horror, the horror......Page 115
Rolling custom controls......Page 119
Multimedia accessibility......Page 127
Summary......Page 130
CHAPTER 5 Canvas......Page 132
Canvas basics......Page 135
Drawing paths......Page 139
Using transformers: pixels in disguise......Page 141
Capturing images......Page 143
Pushing pixels......Page 147
Animating your canvas paintings......Page 151
Summary......Page 157
CHAPTER 6 Data Storage......Page 158
Storage options......Page 159
Web Storage......Page 160
Web SQL Databases......Page 169
Summary......Page 179
CHAPTER 7 Offine......Page 180
The cache manifest......Page 181
The browser-server process......Page 185
ApplicationCache......Page 188
Using the manifest to detect connectivity......Page 189
Summary......Page 191
CHAPTER 8 Drag and Drop......Page 192
Getting into drag......Page 193
Interoperability of dragged data......Page 197
How to drag any element......Page 199
Adding custom drag icons......Page 200
Accessibility......Page 201
Summary......Page 203
CHAPTER 9 Geolocation......Page 204
Sticking a pin in your visitor......Page 205
API methods......Page 207
How it works under the hood: it’s magic......Page 212
Summary......Page 213
CHAPTER 10 Messages, Workers, and Sockets......Page 214
Chit chat with the Messaging API......Page 215
Threading using Web Workers......Page 217
Web Sockets: working with streaming data......Page 229
And finally.........Page 233
C......Page 234
F......Page 235
H......Page 236
M......Page 237
P-Q......Page 238
T......Page 239
X-Z......Page 240