Can I get the name of submit button in another form?

后端 未结 2 1589
孤街浪徒
孤街浪徒 2020-12-20 07:44

I have a form which has 3 submit buttons. Their names are generated and assigned in a loop. Now if I use a post method, how can access the name of the submit button which wa

2条回答
  •  刺人心
    刺人心 (楼主)
    2020-12-20 08:15

    Generate another input element

    
    

    And then get your id with $_REQUEST['buttonId']

提交回复
热议问题