Use .item() accessor for DOM attributes.

Avoid using array-access notation for DOM attribute lists.

Change-Id: Idb38d07b6e56901860faa9a2c0f8ceadea09654f
Escape a single quote so we don't screw up emacs' syntax coloring.

Change-Id: I706eca7b0f44ac8d443a8d695e19a8f85667bb5d