I have this JavaScript (below) that changes the field background if the users enters some text.
$(document).ready(function(){ $('.collection').on('change', 'input', changeColor); $('.normalField').on('change', 'input', changeColor); $('.collection .cf-collection-append').hide(); $('.dropdown').on('change', 'select', changeColor); function changeColor () { if ($(this).val() != '') { $(this).css('background','#ffff99'); } else { $(this).css('background','none'); } } });
However, I need to find a way to change the color of the field on the "approvers" second form. Maybe their is some JavaScript that changes the field background if there is text already in the field?
Thanks in advance
Jonathan