In JavaScript web and mobile apps they have a JavaScript object variable declared automatically as the ID of the UI control so naming is important.

in your case here you would name field2...