js编程常见错误:Uncaught TypeError: XXX is not a function解决
Uncaught TypeError: XXX is not a function解决后台没有错误,前端一直显示Uncaught TypeError: withdraw is not a function错误,代码如下:<div class="form-group btn-right"><button type="button" class="btn btn-primary" i
·
Uncaught TypeError: XXX is not a function解决
后台没有错误,前端一直显示 Uncaught TypeError: withdraw is not a function 错误,代码如下:
<div class="form-group btn-right">
<button type="button" class="btn btn-primary" id="withdraw" onclick="withdraw();">提现</button>
</div>
出现这样的错误是因为 button控件的 id 名和 函数名相同了,执行的时候先找到的是HTML控件,所以会报这样的错误,修改其中一个名称就OK了。
更多推荐
已为社区贡献1条内容
所有评论(0)