html语言确认框,带有HTML5按钮元素的确认对话框(Confirmation dialog with HTML5 button element)…

  • Post author:
  • Post category:其他


带有HTML5按钮元素的确认对话框(Confirmation dialog with HTML5 button element)

我有一个像这样的按钮元素:

它是表格中的数据输入网格的一部分。 在每一行上都有其他按钮,如Update,还有一个带有Insert按钮的新行。 问题是,单击确定时 ,表单未提交。 谷歌搜索这个没有找到我能找到的东西。

行为与使用input onclick不同。 这就是为什么在我看来这不是重复的原因。

I have a button element like so:

It’s part of a data entry grid in a table which is inside a form. On each row are other buttons like Update, and there’s a new row with an Insert button. The problem is that when clicking OK the form is not submitted. A google search on this turned up nothing that I could find.

The behavior is different than for onclick with an input. That is why in my opinion this is not a duplicate.

原文:https://stackoverflow.com/questions/43174421

更新时间:2019-10-19 04:50

最满意答案

只需从button删除form属性button 。

Just remove the form attribute from your button.

相关问答