简体   繁体   中英

How to insert a new div in Ext.window

I need to create a new div which will wrap the exist-ExtJS made one. I aim to insert a CSS propert (background image) for this new div .. Here is scenarios:

<!-- First div is ExtJS made-->
<div class="x-window">

    <!-- I want to create this one to wrap image inserted div below! -->
    <div class="newOne" style="text-align: center;">

        <!-- This div is ExtJS made as well! -->
        <div class="x-window-header" style="background-image: url('Icon.png');></div>

    </div>

</div>

I've used the upper div which is ExtJS made and name of x-window but it did not applied text-align: center; property. I've tried align to center within same x-window-header div element but it did not applied as well!

What is the way to create non-ExtJS made div?

If you want to add css use cls confid and giv class name.

if you want to add image in header do following things:-

first step:-

'cls':'className'

second step:- in your css file

.className .x-window-header{
   background-image: url(...);
}

您可以更改Ext.window.Window的“ renderTpl”属性。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM