Hi,
I am new to the Ext-js. So don't know whether the answer for this question is already available in this forum or not.
I have a TabPanel in my html page
TabPanel
--------------
var tabPanel = new Ext.TabPanel({
id:'doc-body',
region:'center',
margins:'0 5 5 0',
resizeTabs: true,
minTabWidth: 135,
tabWidth: 135,
plugins: new Ext.ux.TabCloseMenu(),
enableTabScroll: true,
activeTab: 0
});
And I wanted add a new tab in to the Tabpanel using the following method.
addTab Method
-------------
function addTab(tabTitle, targetUrl){
tabPanel.add({
title: tabTitle,
iconCls: 'tabs',
autoLoad: {url: targetUrl, callback: this.initSearch, scope: this},
closable:true
}).show();
}
Call 'addTab('Welcome Page','./welcome.html')' method will add a tab to the tabpanel , but it will not load the page.
'welcome.html' is a local page and it's content is a simple paragraph as shown below.
welcome.html
--------------
<p>Welcome<p>
Thanks in advance for ur help.