I have problem with comparing two strings, one is generated from a random “if else” it's called $answer, the other is input from a form, it called $useranswe. If I test to see if there the same it fails but if I say $answer = “HsRtm” then compare it to $useranswer it works.
1. $randomNumber = int(rand(100)) +1; if ($randomNumber < 100 and $randomNumber > 50) { $answer = "kbNtA"; } else { $answer = "WiaNq"; } 2. $answer = “qUfuT”;
1. doesn't work but 2. does.
Can anyone explain to me why does the random statement corrupt the $answer
In reply to Random F%^k up strings! by TroyH
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |