I have a rating form that allows people to be scored and then placed in a graduated group, but I find it hard to understand how this can be done using jQuery or JavaScript.
For example, the first part of my form has a structure where the total values ββfrom each group should be written in the field CombinedScore.
<input id="Food1" name="Food" type="radio" value="5" />
<input id="Food2" name="Food" type="radio" value="10" />
<input id="Food3" name="Food" type="radio" value="15" />
<input id="Drink1" name="Drink" type="radio" value="5" />
<input id="Drink2" name="Drink" type="radio" value="10" />
<input id="Drink3" name="Drink" type="radio" value="15" />
<input name="CombinedScore" type="text" />
The second part is to check the value of the combined account and place it in the appropriate group. for instance
<input id="FoodDrinkGroup1" name="FoodDrinkGroup" type="radio" value="1-10" />
<input id="FoodDrinkGroup2" name="FoodDrinkGroup" type="radio" value="11-20" />
<input id="FoodDrinkGroup3" name="FoodDrinkGroup" type="radio" value="21-30" />
So, if someone credits 10 for food and 15 for drinks, they should be added to 21-30 FoodDrinkGroup.
In general, I have three groups like this, but I hope that if I can get it to work for one, I should use the same code for the rest.
Willb