    domainext = "biz";
    startnumber = "0";
    
    $(document).ready(function(){
    //show news at start
    $("#news").show("slow");
    
    //show news if you click it
    $("#loadNews").click(function(event){
        //show news
        setTimeout(function(){ $("#news").show("slow"); }, 2000);
        //hide all others
        $("#comContent").hide("slow");
        $("#netContent").hide("slow");
        $("#orgContent").hide("slow");
        $("#bizContent").hide("slow");
        $("#topTitle").hide("slow");
    });
    
    //show biz when you click
    $("#loadBIZ").click(function(event){
    //clear biz
    $("#bizContent").empty();
    //hide all others
     $("#news").hide("slow");
     $("#comContent").hide("slow");
     $("#netContent").hide("slow");
     $("#orgContent").hide("slow");
    domainext = 'biz';
     $("#topTitle").text(domainext);
     $("#topTitle").show("slow");
    startnumber = 0;
    getJSON(domainext, startnumber);
    //show biz
    setTimeout(function(){ $("#bizContent").show("slow"); }, 2000);
    });
    
    //show net when you click
    $("#loadNET").click(function(event){
    //clear net
    $("#netContent").empty();
    //hide all others
     $("#news").hide("slow");
     $("#comContent").hide("slow");
     $("#bizContent").hide("slow");
     $("#orgContent").hide("slow");
    domainext = 'net';
     $("#topTitle").text(domainext);
     $("#topTitle").show("slow");
    startnumber = 0;
    getJSON(domainext, startnumber);
    //show net
    setTimeout(function(){ $("#netContent").show("slow"); }, 2000);
    });
    
    //show org when you click
    $("#loadORG").click(function(event){
    //clear org
    $("#orgContent").empty();
    //hide all others
     $("#news").hide("slow");
     $("#comContent").hide("slow");
     $("#bizContent").hide("slow");
     $("#netContent").hide("slow");
    domainext = 'org';
     $("#topTitle").text(domainext);
     $("#topTitle").show("slow");
    startnumber = 0;
    getJSON(domainext, startnumber);
    //show org
    setTimeout(function(){ $("#orgContent").show("slow"); }, 2000);
    });
    
    //end document.ready
    });
    
    function getJSON(domainext, startnumber){
         //get json and output table
           $.get(   'showDomainJSON.php',  
                    { dext: domainext, start: startnumber},  
                    function(data){
                        if(domainext == 'biz'){ tablestorage = $('#bizContent'); }
                        if(domainext == 'net'){ tablestorage = $('#netContent'); }
                        if(domainext == 'com'){ tablestorage = $('#comContent'); }
                        if(domainext == 'org'){ tablestorage = $('#orgContent'); }
                    table = $('<table/>').addClass('domainTable');
                    tbody = $('<tbody/>');
                    currentdata = 0;
                    for(i=1; i <= 50; i++){
                    //make every other row a different background color
                        if( i%2 == 0 ){
                            tr = $('<tr/>').css("background","#d6d7ff");
                        }else{
                            tr = $('<tr/>').css("background", "#ffffff");
                        }
                        for(j=1; j<= 10; j++){
                            tr.append($('<td/>').text(data[currentdata]));
                            currentdata++;
                        }
                        tbody.append(tr);
                    }
                    tablestorage.append(table.append(tbody));
                    },  
                    "json"
            );
    }