View Full Version : Breadcrumb in extjs?
new2extjs
8 Feb 2012, 1:46 AM
Can someone provide hint about how to do breadcrumb in extjs 4?
tvanzoelen
8 Feb 2012, 2:58 AM
Add dynamically buttons to the dockedItems of a panel?
new2extjs
8 Feb 2012, 4:04 AM
Thanks for the reply.
Can you please give me one example of how to create buttons dynamically?
tvanzoelen
8 Feb 2012, 4:10 AM
Ext.onReady(function() {
var toolbar = Ext.createWidget('toolbar', {
renderTo: Ext.getBody(),
items: [
{
text: 'New Button',
iconCls: 'add16',
handler: function() {
toolbar.add({
text: 'breadcrumb',
iconCls: 'add16'
});
}
}
]
});
Ext.createWidget('panel', {
renderTo: Ext.getBody(),
tbar: toolbar,
border: true,
width: 600,
height: 400
});
});
new2extjs
8 Feb 2012, 4:36 AM
Thanks but the text is still static. How can we make it also dynamic? for example the name of the page as we traverse eg. Home->Fashion->Coats which should also be dynamic as well as generic. Any advice?
tvanzoelen
8 Feb 2012, 4:38 AM
Well you can call
toolbar.add({
text: 'breadcrumb',
iconCls: 'add16'
});
from anywhere in your application, make a function out of it
function adCrumb(toolbar, text){
toolbar.add({
text: text
});
}
new2extjs
8 Feb 2012, 4:58 AM
Thanks a lot. I will try this :)
BsdConcept
16 Apr 2012, 1:16 AM
Hi,
Do you have succeeded to do the breadcrumb? Can i have an example?
Thank u
Powered by vBulletin® Version 4.1.5 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.