Change the field instead of the label when validation fails

Step 1. Adding javascript in the header of the page template

Change the highlighted line to whatever you want to do with the field on error and place this code in the header area of the page template(s) (either directly in the header or via an external file):

var errorItems=new Array();
var emptyArray=new Array();
var indexErrorItems=0;

function processErrorItems(){
if(indexErrorItems [...]