小弟自己写的Ext的代码如下,但是不能正常显示:
Ext.onReady(function(){
new Ext.Panel({
renderTo:"hello",
title:"hello",
width:300,
height:200,
html:"<h1>Hello World!!!</h1>",
tools:
[
{id:"save"},
{
id:"help",
handler:function(){Ext.Msg.alert("help","pelase help me!");}
},
{id:"close"}
],
tbar:[{pressed:true,text:"刷新"}]
});
});面板中tools里面的保存、帮助、关闭按钮都不显示,但是给帮助按钮定义的事件是可以执行的,不知道是什么问题,大侠们指点一下吧
Ext.onReady(function(){
new Ext.Panel({
renderTo:"hello",
title:"hello",
width:300,
height:200,
html:"<h1>Hello World!!!</h1>",
tools:
[
{id:"save"},
{
id:"help",
handler:function(){Ext.Msg.alert("help","pelase help me!");}
},
{id:"close"}
],
tbar:[{pressed:true,text:"刷新"}]
});
});面板中tools里面的保存、帮助、关闭按钮都不显示,但是给帮助按钮定义的事件是可以执行的,不知道是什么问题,大侠们指点一下吧
var temp=new Ext.Panel({
renderTo:"hello",
title:"hello",
width:300,
height:200,
html:" <h1>Hello World!!! </h1>",
tools:
[
{id:"save"},
{ id:"help",
handler:function(){Ext.Msg.alert("help","pelase help me!");}
},
{id:"close"}
],
tbar:[{pressed:true,text:"刷新"}]
}); var win = new Ext.Window({
title: 'abc',
closable:true,
width:600,
height:350,
//border:false,
plain:true,
layout: 'border', items: [temp]
}); win.show(this);
}); 大半年没有搞过,也不知对不对,搞好的话回一下
我都不知道你对save除id之外没有做任何定义,你想让他怎么显示。