I’m working on a quiz and I have a variable containing the anwer to a question:
var answer=“Constantine”;
On screen there’s an input text box which gets the user to enter their answer. The input text var is txt. I then compare txt with answer to see if they are the same:
if(_root.answer==_root.txt)
{
//do stuff here
}
Unfortunately it doesn’t work because the txt var includes a load of html stuff as well as the word Constantine even if the user types it correctly. It’s probably really basic stuff but what do I do to get round this?