chrome浏览器Uncaught TypeError: object is not a function问题

来源:互联网 发布:金山打字软件 编辑:程序博客网 时间:2024/04/30 20:11

刚刚chrome浏览器提示 object is not a function,找了半天发现问题是我有一个按钮,id和方法重复了,所以提示这个。


            <input id="buttonAdd" type="button" value="add" onclick="buttonAdd()"  />
这样写会导致错误。