Does anyone know how to create a variable ID. basically this is - TopicsExpress



          

Does anyone know how to create a variable ID. basically this is what I need to do and im stumped everything I try has been a fail. I have a test with a bunch of check boxes/radio buttons. I created an array with the Question, Answer, and score. I am trying to go through the array and find the button that coinsides with the array and check if the value is correct, .. I cant seem to make the loop pick up the right name for the IDs its all showing as undefined.. this is what I have: any guidance would be super helpful, Thanks!! for (var i=0, len = ansKey.length; i < len; i++) { tmpID = # + ansKey[i][0]; if( $(tmpID).attr(value) == ansKey[i][1]){ totalSum = + ansKey[i][2]; } }
Posted on: Mon, 05 May 2014 20:35:02 +0000

Trending Topics



Recently Viewed Topics




© 2015