+ 1

How is this wrong?

Forget imports and include. Those third party files are all correct. The problem is that my code in index.php from line 17 and beyond. No matter what the outcome, only the else works. Why is this happening? https://code.sololearn.com/WOJHzCh2h82O/?ref=app https://code.sololearn.com/WJVDOL0ct0po/?ref=app

12th Jul 2020, 2:05 PM
Fábio Gonçalves
Fábio Gonçalves - avatar
3 Respostas
0
Well, I'm not too sure here, but how about printing <resultado> on screen (in console, or alert() it) and see whether it contains something you expected ...
12th Jul 2020, 2:38 PM
Ipang
0
How do I do that?
12th Jul 2020, 2:53 PM
Fábio Gonçalves
Fábio Gonçalves - avatar
0
Add either console.log(resultado); Or alert(resultado); Just before you check it in the following line in <script> if(resultado == 0)
12th Jul 2020, 3:11 PM
Ipang