var toppanel = Ext.create('Ext.panel.Panel',{ layout : { type : 'absolute' }, bodyStyle : { background : '#0B5EAA url(../images/index_top_bg.jpg) no-repeat', padding: '10px' }, bbar : ['->',{ id:'pButton',//按钮id xtype : 'button', cls : 'images/id_bg.png', text : jsp_index_pending, handler : function(){ //点击执行的方法体 } }] });