Results 1 to 3 of 3

Thread: Need some help

  1. #1

    Question Need some help

    Hello guys!

    I need your help.
    I currently work with ExtJS for first time.
    So, excuse me for bad description and bad english

    I want to use ExtJS with my SQL-database, but I have some problems with it.

    I write the query, from two specific tables. And I wrote with Javascript a function which I can use to extract the IP-address out of the addressbar.

    var GET = new Array();
               if( > 0) {
                  var get_param_str =,;
                  var get_params = get_param_str.split("&");
                  for(i = 0; i < get_params.length; i++) {
                     var key_value = get_params[i].split("=");
                     if(key_value.length == 2) {
                        var key = key_value[0];
                        var value = key_value[1];
                        GET[key] = value;
              alert(GET['ip']+ GET['view']);
    It works fine.

    the tabpanel displays my devices(that is written in the table of the database) in different tabs in a table(grid).

    Now, how can I tell Ext, that:

    If the IP-number is 123.456.12.34
    then show the tab.
    If the number is 777.666.555.44
    then show a different tab and the other tab is closed.

    I have to link the showing advice (the tabs) with the ip-number written in addressbar.

    By now I'm totally confused

    Please help!!



    p.s.: If someone doesn't understand me, please write

  2. #2
    Sencha User
    Join Date
    Apr 2008
    West Linton, Scotland


    Use the setActiveTab method on the tab object.
    If you read the docs API for TabPanel you will see this method and other methods.

    function setTabBasedOnIp(){
    if(ip == ip number){
    else if(ip == other ip number){

  3. #3

    Thumbs up

    Thanks for your help!

Posting Permissions

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