Each scripting language has its own conventions for referring to HTML objects from
within a script. This specification does not define a standard mechanism for referring to HTML objects.
However, scripts should refer to an element according to its assigned name.
Scripting engines should observe the following precedence rules when identifying an element: a name attribute takes precedence over an id if both are set. Otherwise, one or the other may be used.