Here ??™ s the code to add, specifying the desired element as the
getElementById() parameter:
< script type=???application/x-javascript??? >
var DOMViewerObj = document.getElementById(???Jack_Armitage???)
var DOMViewerName = null;
< /script >
Chapter 12: Testing and Debugging
278
Figure 12-13: Specifying a root node for the DOM Viewer
Because it will reference the desired element directly by getElementById() , you can add this code in
your HTML page after the element you wish to examine in the body but not before it.
Go to brainjar.com/dhtml/domviewer for full details on the DOM Viewer.
Index A
addColorStop() method, 138
addEventListener function, 68??“69,
71??“72, 106
aggregators, 17
AJAX
external URLs and, 42??“45
links, 72??“74
animation, creating, 144??“146
Apple Mighty Mouse, 8
applications
aggregators, 17
categories, 17
data URLs and, 226
constraints, 227
issues with, 227
modes, 20
UI access, 21
native, 15
aggregators, 17
task-based, 17
widgets, 17
offline, 227??“231
converting to data URLs, 234??“236
embedding external styles and scripts,
231??“233
images, encoding, 233??“234
phone calls from, 159??“161
task-based, 17
widgets, 17
arcs, 128??“130
aspect ratio, video, 148??“149
audio files, embedding, 151??“152
B
Back button, 22
background, multiple images, 93??“94
bandwidth
CSS and, 211
images and, 210
JavaScript and, 211
minimizing, 210??“211
beginpath() function, 127
best practices in design, 28??“31
bit rate, video, 147??“148
block elements
gradient push buttons, 91??“93
image-based borders, 90
rounded corners, 91
blocks, 187??“190
bookmarklets, 221
adding, 223??“224
uses, 224??“226
borders, image-based, 90
button bar, 24
buttons, CSS-based, 95??“98
C
canvas, 123??“124
animation, 144??“146
context, 124??“125
properties, 125
drawing shapes, 127??“130
images, drawing, 131??“135
rectangles, 125??“127
state, 142??“144
canvas element, 124
canvasGradient object, 136
case studies
iRealtor 2.
Pages:
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306