I have beautifully formatted background-color changes based on radio button inputs, but the format changes do not transfer to the saved document in the repository. Several posts say that input values are changed to divs when the read-only doc is created, but I'm not sure how to address that in my current script.
------------------------------------------------------
.item class assigned to all radio buttons
.comment class assigned to all comment boxes
.uploads class assigned to all upload buttons
------------------------------------------------------
Any help is greatly appreciated!
In the live form:
In the saved form:
$(document).ready(function(){ $('.item input').change(function(){ const liNext = $(this).closest('li').next('li'); //set the variable for the next <li> after the item (= Comments Box) const liNextNext = liNext.closest('li').next('li'); //set the variable for the next <li> after the comment box (= Upload) if ($(this).val() == 'unsatisfactory'){ $(this).closest('li').css('background-color', '#ffe6e6'); liNext.css('background-color', '#ffe6e6'); liNextNext.css('background-color', '#ffe6e6'); } if ($(this).val() == 'satisfactorycomment'){ $(this).closest('li').css('background-color', '#fff2e6'); liNext.css('background-color', '#fff2e6'); liNextNext.css('background-color', '#fff2e6'); } else if ($(this).val() == 'satisfactory'){ $(this).closest('li').css('background-color', 'transparent'); } }); });