PHP simple maths quiz program

后端 未结 2 1350
野趣味
野趣味 2021-01-27 09:59

I\'m trying to create a maths quiz page. The first page needs to generate a question shown as a header, that asks the user what two random numbers are multiplied together. Then

相关标签:
2条回答
  • 2021-01-27 10:24

    You must have the header() code before any output, especially that echo statement.

    0 讨论(0)
  • 2021-01-27 10:38

    Apart from sending the headers before you output something, i think your form action is wrong, it should be

    action="<?php echo $_SERVER['PHP_SELF']; ?>"
    

    You are sending the POST via FILE protocol, it won't be processed by Web Server/PHP.

    And also, you are not POSTing "first" and "second" fields.

    0 讨论(0)
提交回复
热议问题