Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 697317
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T03:09:20+00:00 2026-05-14T03:09:20+00:00

I have a border layout in ExtJS, The north region contains some HTML, but

  • 0

I have a border layout in ExtJS,

The north region contains some HTML, but also needs to contain a toolbar like this…

So i’ve managed to get the border layout set up, added the html to the North Region of the layout, but I can’t find any workable examples of how to implement a tool bar.

I have found lot’s of examples of toolbars on their own, but I’ve not got the luxury or learning ExtJs thoroughly so it’s all greek to me.

I suspect there’s a way to define a tool bar outside of the cumbersome JSON style flow of creating a layout and somehow attaching it to the region, and I’m hoping it’s relativley simple to do. If someone can explain how I’d do this, it would really help.

Here’s the code so far…

//make sure YOUR path is correct to this image!!
Ext.BLANK_IMAGE_URL = '../../ext-2.0.2/resources/images/default/s.gif';


//this runs on DOM load - you can access all the good stuff now.

Ext.onReady(function(){
    var viewport = new Ext.Viewport({
        layout: "border",
        border: false,
        renderTo: Ext.getBody(),
        items: [


        // ------------------------------------------------------------------
        {
            region: "north",
            id : "toolbar-area",
            xtype: 'panel',
            html: [ "<div id=\"html-header\">",
                    "<div id=\"council-logo\"></div>",
                    "<ul id=\"ancillary-menu\">",
                        "<li><a href=\"#\">Logout</a></li>",
                        "<li><a href=\"#\">Gazeteer Home</a></li>",
                        "<li>Hello Rachel</li>",
                    "</ul>",
                    "<img id=\"inteligent-logo\" src=\"applied-images/logos/inteligent.gif\">",
                    "</div>" ],

            /* ++++++++++++++++++++++++++++++++++++++++++++ */
            /* The toolbar needs to go around here....      */
            /* ++++++++++++++++++++++++++++++++++++++++++++ */

            height: 100
        },

        // ------------------------------------------------------------------
        // WEST
        // ------------------------------------------------------------------
        {
            region: 'west',
            xtype: 'panel',
            split: true,
            resizeable: false,
            maxWidth : 350,
            minWidth : 349,
            collapsible: true,
            title: 'Gazetteer Explorer',
            width: 350,
            minSize: 150,

            // --------------------------------------------------------------

            title: 'Nested Layout',
            layout: 'border',
            border: false,
            id: "west",
            items: [

                {
                    // ***********************************************
                    // Search Form
                    // ***********************************************

                    region : "north",
                    height: 300,
                    split : true,
                    id : "left-form-panel",
                    items : [{

                        xtype : "form",
                        id : "search-form",
                        items : [

                            // Authority combo box
                            // ===============================
                            {
                                xtype : "combo",
                                fieldLabel : "Authority",
                                name : "authority",
                                hiddenName : "authority",
                                id : "authority-combo"
                            },
                            // ===============================

                            // Search Fieldset
                            // ===============================
                            {
                                xtype : "fieldset",
                                autoHeight : true,
                                title : "Search by...",
                                id : "search-fieldset",
                                items : [

                                    // Ref Number text Box
                                    // %%%%%%%%%%%%%%%%
                                    {

                                        xtype : "textfield",
                                        name : "ref-number",
                                        fieldLabel : "Ref. Number",
                                        id : "ref-number-textfield"

                                    },
                                    // %%%%%%%%%%%%%%%%
                                    // Streetname Combo
                                    // %%%%%%%%%%%%%%%
                                    {

                                        xtype : "combo",
                                        name : "street-name",
                                        hiddenName : "street-name",
                                        fieldLabel : "Street Name",
                                        id : "street-name-combo"

                                    },
                                    // %%%%%%%%%%%%%%%%
                                    // Postcode Combo
                                    // %%%%%%%%%%%%%%%%
                                    {

                                        xtype : "combo",
                                        name : "postcode",
                                        hiddenName : "postcode",
                                        fieldLabel : "Postcode",
                                        id : "postcode-combo"

                                    },
                                    // %%%%%%%%%%%%%%%%

                                    // Postcode Combo
                                    // %%%%%%%%%%%%%%%%
                                    {

                                        xtype : "combo",
                                        name : "town",
                                        hiddenName : "town",
                                        fieldLabel : "Town",
                                        id : "towm-combo"

                                    },
                                    // %%%%%%%%%%%%%%%%

                                    // Postcode Combo
                                    // %%%%%%%%%%%%%%%%
                                    {

                                        xtype : "combo",
                                        name : "locality",
                                        hiddenName : "locality",
                                        fieldLabel : "Locality",
                                        id : "locality-combo"

                                    },
                                    // %%%%%%%%%%%%%%%

                                     // Search Button
                                    // %%%%%%%%%%%%%%%%

                                    {
                                        xtype : "button",
                                        text : "Search",
                                        id : "search-button"
                                    },  

                                    // Reset Button
                                    // %%%%%%%%%%%%%%%

                                    {
                                        xtype : "button",
                                        text : "Reset",
                                        id : "reset-button"
                                    } 


                                ]
                            },
                            // =======================


                        ]

                    }]

                    // *********************************************

                },

                {
                    region: 'center',
                    html: 'Tree view goes here'
                }

            ]



        },

        // ------------------------------------------------------------------
        {
            region: 'center',
            xtype: 'panel',


            // --------------------------------------------------------------
              layout: 'border',
              border: false,
              items: [

                  {
                    region: 'center',
                    height: 200,
                    split: true,
                    html: 'Map goes here'
                  },

                  {
                    region: 'south',
                    title: "Selection", 
                    split: true,
                    height: 200,
                    collapsible: true,
                    html: 'Nested Center'
                  }

              ]
        },

        // ------------------------------------------------------------------
        {
            region: 'east',

        },

        // ------------------------------------------------------------------

        {
            region: 'south',
        }]


    }); 
});

Sorry there’s so much code, but ExtJS makes me scared to touch anything that’s working.

  • 1 1 Answer
  • 3 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T03:09:21+00:00Added an answer on May 14, 2026 at 3:09 am

    just add

    bbar: [
       // YOUR ITEMS HERE EXAMPLE FOLLOWING
       {
           xtype: 'button',
           text: 'test Button',
           handler: function(btn){
               alert('Button Click');
           }
       }
    ]
    

    to your config (where xtype === panel)

    it would look like something like this :

        {
            region: "north",
            id : "toolbar-area",
            xtype: 'panel',
            html: [ "<div id=\"html-header\">",
                    "<div id=\"council-logo\"></div>",
                    "<ul id=\"ancillary-menu\">",
                        "<li><a href=\"#\">Logout</a></li>",
                        "<li><a href=\"#\">Gazeteer Home</a></li>",
                        "<li>Hello Rachel</li>",
                    "</ul>",
                    "<img id=\"inteligent-logo\" src=\"applied-images/logos/inteligent.gif\">",
                    "</div>" 
                  ],
            bbar: [
               {
                   xtype: 'button',
                   text: 'test Button',
                   handler: function(btn) {
                     alert('Button Click');
                   }
               }
            ],
            height: 100
        }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a border layout whose center panel is defined like the below. {
I have a border layout with 4 panels, north, south, east and west. For
EXT V. 3.01 I have a view port with border layout. The center region
So I have a layout like this: div { border: 1px solid } <div
I have an ExtJS Viewport with a container that has the border layout and
I would like to have fuzzy looking border around my Canvas control. Basically, I
I have ExtJS View-Port panel , that contain center panel, that contain tablpanel ,
I have such Layout structure: 1) First lays SimpleLayoutPanel main (green border) 2) I'd
I have a border layout set on a widget using Ext-GWT. Is there a
I have this page layout: <header> <content> <footer> I have border-left and right applied

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.