Results 1 to 7 of 7

Thread: [SOLVED] form elements loose label

  1. #1
    Sencha User nadeemshafi9's Avatar
    Join Date
    Mar 2009
    Location
    Bucks, Hearts - UK
    Posts
    192

    Default [SOLVED] form elements loose label

    Hi guys

    Why is it that when you put form elements inside a tab panel or give there container a layout they loose there default label ? anjd how do you get around it ?

    thanks

  2. #2
    Sencha User conorarmstrong's Avatar
    Join Date
    Mar 2008
    Location
    Northern Ireland
    Posts
    224

    Default

    can we see some code?
    ------------------------------------------
    Conor Armstrong
    tw: @evathedog
    web: rockstown.com

    Ext.ux.form.AutoCombo
    Ext.ux.SimpleIFrame
    Ext.ux.form.ToolFieldSet

    Knowledge is realising that the street is one-way, wisdom is looking both directions anyway.

  3. #3
    Sencha User nadeemshafi9's Avatar
    Join Date
    Mar 2009
    Location
    Bucks, Hearts - UK
    Posts
    192

    Default

    heres some code but teh thing is that i tried label width on teh form but it doesent efect it i m putting it in a tab because i whant to put a textarea in the other tab for a description.


    Code:
    xtype: 'form',
                                columnWidth: 1,
                                labelWidth: 75,
                                id: 'updatemovieFormPanel',
                                border: false,
                                bodyStyle : 'padding:10px 10px 10px 10px;',
                                items: [{
                                    xtype: 'tabpanel',
                                    height: 610,
                                    deferredRender: false, 
                                    activeItem: 'tab1',
                                    id: 'tabPanel1',
                                    border: false,
                                    items: [{
                                        id:'tab1',
                                        title: 'Details',
                                        listeners: {
                                             activate: function(panel) {
                                                 panel.show();
                                             }
                                        },
                                        items: [{
                                            xtype: 'hidden',
                                            name: 'id',
                                            value: m[0].data.id
                                        },{
                                            xtype: 'textfield',
                                            name: 'movie_type',
                                            allowBlank: false,
                                            emptyText: 'movie_type',
                                            fieldLabel: 'movie_type',
                                            value: m[0].data.movie_type
                                        },{
                                            xtype: 'textfield',
                                            name: 'order',
                                            allowBlank: false,
                                            emptyText: 'order',
                                            fieldLabel: 'order',
                                            value: m[0].data.order
                                        },{
                                            xtype: 'textfield',
                                            name: 'name',
                                            allowBlank: false,
                                            emptyText: 'name',
                                            fieldLabel: 'name',
                                            value: m[0].data.name
                                        },{
                                            xtype: 'textfield',
                                            allowBlank: false,
                                            name: 'source_type',
                                            emptyText: 'source_type',
                                            fieldLabel: 'source_type',
                                            value: m[0].data.source_type
                                        },{
                                            xtype: 'textfield',
                                            allowBlank: false,
                                            name: 'url',
                                            emptyText: 'url',
                                            fieldLabel: 'url',
                                            value: m[0].data.url
                                        },{
                                            xtype: 'textfield',
                                            allowBlank: false,
                                            name: 'desc',
                                            emptyText: 'desc',
                                            fieldLabel: 'desc',
                                            value: m[0].data.desc
                                        },{
                                            xtype: 'textfield',
                                            allowBlank: false,
                                            name: 'img',
                                            emptyText: 'img',
                                            fieldLabel: 'img',
                                            value: m[0].data.img
                                        }]
                                    }]
                                }]
                            }]
                        });
                        updatemovieWindow.show();

  4. #4
    Sencha User Animal's Avatar
    Join Date
    Mar 2007
    Location
    Bédoin/Nottingham
    Posts
    30,890

    Default

    As emphasized in the API documentation, labels are added around fields by the FormLayout layout manager.

  5. #5

  6. #6
    Sencha User nadeemshafi9's Avatar
    Join Date
    Mar 2009
    Location
    Bucks, Hearts - UK
    Posts
    192

    Default

    so what your saying is once inside a tab panel teh labels will not be rendered by form layout anymore? and how do i get them to be rendered.

  7. #7
    Sencha User nadeemshafi9's Avatar
    Join Date
    Mar 2009
    Location
    Bucks, Hearts - UK
    Posts
    192

    Default

    coool ok so i didnt know there was an explicit form layout ?? it works now that i gave the tab a form layout
    layout:'form'

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •