i wrote the following script to hide subquestions based on the answer values of the previous question. and it works great.
<script type="text/javascript">
$(document).ready(function() {
var i = 0;
for (i=0;i<=9;i++) {
var prevQA = $("#java95735X7X201"+i).val();
if (prevQA != "0" && prevQA != "1") $("#javatbd95735X7X293"+i).hide();
}
});
</script>
however, it only works when the previous question's answer values show up as hidden inputs on the current question i'm working with. for example:
<input type='hidden' name='java95735X7X2011' id='java95735X7X2011' value='2' />
for some unknown reason, these hidden input values only show up SOME OF THE TIME for me! i can't figure out why. does anybody have a clue?