Hello,
I have this function in my ASP page:
function calcScore() {
var score=0;
var numCorrect = 0;
for (i=0 ; i<numQuestions ; i++) {
if (answer[i] == correctAnswer[i]) {
numCorrect = numCorrect + 1;
score=(numCorrect/numQuestions)*10;
}
}
alert('Your score is ' + score);
if(score >=5)
alert('you pass');
else
alert('you fail');
window.location="login.asp"
I want to open here my database and put in my table the score. Is this possible in a javascript function?