2 shiyibodec shiyibodec 于 2015.06.11 15:30 提问

extj报错IndexOutOfBoundsException: Index: 0, Size: 0
 <!DOCTYPE HTML>
<html manifest="">
<head>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta charset="UTF-8">

    <title>test</title>

    <!-- The line below must be kept intact for Sencha Cmd to build your application
    <script id="microloader" type="text/javascript" src="bootstrap.js"></script> -->
    <link rel ="stylesheet" type="text/css" href="ext/packages/ext-theme-neptune/build/resources/ext-theme-neptune-all.css" />
    <script type="text/javascript" src="ext/build/ext-all.js"></script>
    <script type = "text/javascript" src = "ext/packages/ext-theme-neptune/build/ext-theme-neptune.js"></script>
</head>
<body>
<script>
    Ext.define('Person',{
        name : 'xiaozhang',
        sayName : function() {
            console.log(this.name);
        }
    });
    Ext.define('Student',{
        extend : 'Person'
    });

    var student = Ext.create('Student');
    student.sayName();

</script>
</body>
</html>

1个回答

showbo
showbo   Ds   Rxr 2015.06.11 20:04

什么版本的ext?ext-4.1.1a测试你的代码没有问题

showbo
showbo 回复shiyibodec: ext-5.0.1测试也没有问题,确认你是官网下载的,不会下载别人修改过的吧
2 年多之前 回复
shiyibodec
shiyibodec extjs5.0版本
2 年多之前 回复
Csdn user default icon
上传中...
上传图片
插入图片