【发布时间】:2017-10-09 05:19:08
【问题描述】:
当我单击自定义工具栏按钮时,我试图调用一个函数。我想看看是否通过在其中实现 alert() 函数来调用该函数。它不会触发任何消息。知道如何通过单击警报旁边的按钮来检查该功能是否被触发?
代码:
....
toolbar: [
{template: '<a class="k-button" onclick="removeLicense()">Ukloni licencu</a>'}
],
...
function removeLicense() {
// window.kendoAlert("hello");
alert("hello");
}
【问题讨论】:
-
你的函数有
<script></script>标签吗? -
为什么不 onclick="alert("hello")"
标签: javascript jquery user-interface kendo-ui kendo-mobile