Get submit button value in PHP

后端 未结 5 1570
天命终不由人
天命终不由人 2021-01-17 06:10

I would like to test my button can get the current value from the date\'s textbox? I got the value of submit button but I couldn\'t find any code get name of the button. So

5条回答
  •  萌比男神i
    2021-01-17 06:39

    You can do:

    if ($_POST['oprf'] == '' || $_POST['oprf'] == NULL) {
    //this checks to see if there has been a value that was sent with the
    //form
    }
    

    I usually use isset for cookies.

提交回复
热议问题