Fix escaping attributes.

Removed [0] which did not fit with the current spec.