easyui 异常:Uncaught TypeError: Cannot read property 'tabs' of undefined
来源:互联网 发布:淘宝返利网站 编辑:程序博客网 时间:2024/05/18 02:40
<script type="text/javascript"> $("div[node-id=home_manager]").click(function() {//alert();//判断选项卡是否打开,如果已经打开使用打开这个,如果没有打开创建新的选项卡var e = $("#tt").tabs("exists","主页管理");if(e) {//已经打开$("#tt").tabs("select","主页管理");} else {//创建新的$('#tt').tabs('add',{title: '主页管理',iconCls: 'icon-reload',closable: true,content: '<iframe frameborder="0" width="100%" height="100%" src="homeManager.do"></iframe>'}); } })})</script>html代码<div class="easyui-accordion" data-options="fit:true"><div title="电商管理"><ul id="tt" class="easyui-tree"><li><span>商城管理</span><ul><li><span>商品分类</span><ul><li><span><a href="#">电子商城</a></span></li><li><span>美食小吃</span></li><li><span></span></li></ul></li><li><span>商品添加</span></li><li><span><a href="#" id="listAll">商品管理</a></span></li></ul></li><li><span><a href="javascript:void()" >商品展示</a></span></li></ul></div></div></div></div><div data-options="region:'center'"><div id="tt" class="easyui-tabs" style="width:500px;height:250px;"></div> </div>
我的html代码里边有两个id="tt",导致在用id选择器的时候,在某一个id上没有找到这个元素具有tabs方法,所以导致这个错误出现,耽误了大半天
再遇到此类错误,记得先看id选择器里的id值一定不要重复
阅读全文
0 0
- easyui 异常:Uncaught TypeError: Cannot read property 'tabs' of undefined
- Uncaught TypeError: Cannot read property 'tabs' or '' of undefined
- easyui使用时出现这个Uncaught TypeError: Cannot read property 'combo' of undefined
- Extjs4---Uncaught TypeError: Cannot read property ‘items’ of undefined
- 【StackFlow】Uncaught TypeError: Cannot read property 'pageCount' of undefined
- Ckeditor: Uncaught TypeError: Cannot read property 'keyCode' of undefined 解决方法
- Uncaught TypeError: Cannot read property 'msie' of undefined问题解决方案
- Uncaught TypeError: Cannot read property 'options' of undefined 错误
- Uncaught TypeError: Cannot read property 'length' of undefined
- 错误:Uncaught TypeError: Cannot read property 'WebSocket' of undefined
- Uncaught TypeError: Cannot read property 'value' of undefined
- Uncaught TypeError: Cannot read property 'plugin' of undefined
- react Uncaught TypeError: Cannot read property 'title' of undefined
- Uncaught TypeError: Cannot read property 'width' of undefined
- Uncaught TypeError: Cannot read property 'substring' of undefined
- Uncaught TypeError: Cannot read property 'PRINT_INIT' of undefined user:100
- Uncaught TypeError: Cannot read property 'substring' of undefined
- extjs4:Uncaught TypeError: Cannot read property 'processed' of undefined
- Android运行时权限(危险权限)
- 使用rsa公钥对字符串加密并通过私钥解密全过程
- svn clean up 报.svn下 pristine 无法移动
- ROS indigo 下 gazebo6 安装与测试
- 商人过河 决策
- easyui 异常:Uncaught TypeError: Cannot read property 'tabs' of undefined
- kafka->spark->streaming->mysql(scala)实时数据处理案列
- cocoapods相关的linux命令
- 云服务器Centos6.8安装配置samba文件共享
- java-无法新建servers的问题
- 如何写SysV服务管理脚本
- 设计模式 单例模式
- 【翻译】VTK 8.0.0
- 记:为何我设置了session为永久保存,但是并没有什么卵用