ExtJs学习笔记(16)_Form布局

这是最重要的一个布局,几乎所有的表单界面都可以采用form布局,详细的用法本文不作讨论(可以查阅官方API文档),这里只给出一个简单的示例

< script type = " text/javascript " >
ExpandedBlockStart.gifContractedBlock.gif    Ext.onReady(
function ()  {
ExpandedSubBlockStart.gifContractedSubBlock.gif        
var win = new Ext.Window({
            title: 
"form Layout",
            height: 
150,
            width: 
230,
            plain: 
true,
            bodyStyle: 
'padding:15px',
            items: 
ExpandedSubBlockStart.gifContractedSubBlock.gif            
{
                xtype: 
"form",
                labelWidth: 
30,
                defaultType: 
"textfield",
                frame:
true,
                items: 
                [
ExpandedSubBlockStart.gifContractedSubBlock.gif                    
{
                        fieldLabel:
"姓名",
                        name:
"username",
                        allowBlank:
false
                    }
,
ExpandedSubBlockStart.gifContractedSubBlock.gif                    
{
                        fieldLabel:
"呢称",
                        name:
"nickname"
                    }
,
ExpandedSubBlockStart.gifContractedSubBlock.gif                    
{
                        fieldLabel: 
"生日",
                        xtype:
'datefield',
                        name: 
"birthday",
                        width:
127
                    }

                ]
            }

        }
);
        win.show();
    }
);
< / script>

效果图:
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值