var tab = Ext.create('Ext.TabPanel', {
id:'myTabPanel',
region:'center',
layout: 'fit',
itemId: 'center-tabs',
items : [{
id:'home',
title : "Home Page",
iconCls: 'House',
html : '<iframe src= "jsp/homepage.jsp" width="100%" height="100%" marginwidth="0" framespacing="0" marginheight="0" frameborder="0" ></iframe>',
/*loader: { url:'jsp/homepage.jsp', loadMask: 'loading...', autoLoad: true, scripts: true },*/
listeners:{
activate:function(tab){
}
}
}]
});
試了好多方法都沒用
this.loader.load();
tab.getUpdater().refresh();
this.getActiveTab().refresh();
給iframe增加id,用js更新就好
html : '<iframe src= "jsp/homepage.jsp" id="myifr" width="100%" height="100%" marginwidth="0" framespacing="0" marginheight="0" frameborder="0" ></iframe>'
document.getElementById('myifr').contentWindow.location.reload()