PDA

View Full Version : add simple image tag as item to window



gimler
27 Nov 2007, 6:12 AM
i will simple add a image to the window but it make 2 divs around it how can i kill the divs?



var window = new Ext.Window({
title:'Login'
, width:500
, closable:false
, resizable:false
, layout:'fit'
, plain:true
, border:false
, items:[{html:'<img src="http://extjs.com/forum/images/buttons/reply.gif" height="250" width="500" />'}]
, buttons:[{
text:'login'
, form:form.form
, handler:function(bt){bt.form.submit()}
}]
});

window.show();

27 Nov 2007, 6:42 AM
instead of an item, try:


html : String/Object
An HTML fragment, or a DomHelper specification to use as the panel's body content (defaults to '').

gimler
27 Nov 2007, 7:11 AM
i have more then one item



items: [{html:'<img src="http://extjs.com/forum/images/buttons/reply.gif" height="250" width="500" />'}, panel1, panel2....]

27 Nov 2007, 7:38 AM
When you post the HTML as an item EXT assumes that you are asking for an Ext.Panel object. You probably need to specify new Ext.BoxComponent.

gimler
27 Nov 2007, 8:06 AM
sorry but i don