replace most vanilla js code with jQ code; \nmake custom field names work