function MenuBuild()
{

var arrow_d = "images/arrow_d.gif";
var arrow_r = "images/arrow_r.gif";
var mmFont_color = "696969";

is = new BrowserCheck();                    //Cheking browser version
TE=new TreeItem(0,0,"rad_items","","");//Creating menu object
if(!W)W=900;                                         //defining default browser width
//TE.xpos=(W-400)/2+28;                                //X position
TE.xpos=230;                                //X position
TE.ypos=44;                                             //Y position
TE.align="hor";                                    //hor -horisontal vert - vertical alignment
TE.bckColor="#F5F5F5";                     //Back Color
TE.selBckColor="#E2E2E2";               //Selected back color
TE.fntColor="#696969";                      // Font Color
TE.selFntColor="#696969";                // Selected font color
TE.width=85;                                       //Menu column width
TE.fntSize=1;                                        // Font Size
TE.i=false;                                              //font italic
TE.b=false;                                             //font bold
TE.face="Verdana, Geneva, Arial, Helvetica, sans-serif";                             //Font Face
TE.u=false;                                             //font underlined
TE.iHeight=20;                                     //Menu item height
TE.imWidth=7;                                   // Icon width
TE.bSize=1;                                           //Border size
TE.bColor="#C0C0C0";                         // Border color
TE.d=1;                                                   // delimeter size 
TE.arrIm = arrow_d;
TE.arrIm1 = arrow_r;


//Creating menu structure 

//TE.A(ID, ParentID, Text, Link, Target, Icon, iconR, ItemWidth,ItemHeight); 
where:
//ID- identifier (any unical string)
//ParentID  - identifier of parent item 
//Text - menu item text
//Link - menu item URL
//Target - frame or reserved word : _top _self ....
//Icon - menu icon
//iconR - rollover icon
//ItemWidth - individual menu item width
//ItemHeight - individual menu item height

// glowne menu
TE.Get(0).bSize=0; // bez ramki
TE.Get(0).d=1; // bez delimitera

//**************************************************************************************************
//                  O firmie
//**************************************************************************************************
TE.A(1,0,"O firmie","","","","",85,20);
TE.A(2,1,"O nas","index.php?m_id=12","","","",140,20);
TE.A(3,1,"Referencje","index.php?m_id=14","","","",140,20);
TE.A(4,1,"Certyfikaty","index.php?m_id=15","","","",140,20);
TE.A(5,1,"Polityka jakości i kontroli obrotu","index.php?m_id=18","","","",140,40);
//TE.A(6,1,"Galeria foto","index.php?m_id=16","","","",140,20);
//TE.A(7,1,"Piszą o nas","index.php?m_id=17","","","",140,20);
TE.A(6,1,"Nagrody","index.php?m_id=3015","","","",140,20);

TE.Get(1).arrIm = arrow_d;
TE.Get(1).arrIm1 = arrow_d;
TE.Get(1).bSize=1;
TE.Get(1).d=1;
TE.Get(1).fntColor=mmFont_color;
TE.Get(1).b=true;
TE.Get(2).b=true;
TE.Get(3).b=true;
TE.Get(4).b=true;
TE.Get(5).b=true;
TE.Get(6).b=true;
//TE.Get(7).b=true;
//TE.Get(7).b=true;
//**************************************************************************************************
//                  Kontakty
//**************************************************************************************************
TE.A(8,0,"Kontakty","index.php?m_id=22","","","",75,20);
TE.Get(8).fntColor=mmFont_color;
TE.Get(8).b=true;

//**************************************************************************************************
//                  Oferta
//**************************************************************************************************
TE.A(9,0,"Oferta","","","","",75,20);
TE.Get(9).arrIm = arrow_d;
TE.Get(9).arrIm1 = arrow_d;
TE.Get(9).bSize=1;
TE.Get(9).d=1;
TE.Get(9).fntColor=mmFont_color;
TE.Get(9).b=true;

//TE.A(10,9,"Systemy łączności i transmisji danych","index.php?m_id=3000","","","",160,40);
//TE.A(11,10,"Tetra","","","","",160,20);
/*
TE.A(12,10,"Tranking analogowy","index.php?m_id=163","","","",160,20);
TE.A(13,10,"Sieci dyspozytorskie","index.php?m_id=164","","","",160,20);
TE.A(14,10,"Transmisja danych","index.php?m_id=165","","","",160,20);
TE.A(15,10,"Inne","index.php?m_id=166","","","",160,20);
*/

//TE.Get(10).arrIm = arrow_r;
//TE.Get(10).arrIm1 = arrow_r;

TE.A(16,9,"Radiotelefony cywilne","index.php?m_id=3001","","","",160,20);
/*
TE.A(17,16,"Doręczne","index.php?m_id=172","","","",160,20);
TE.A(18,16,"Przewoźne","index.php?m_id=173","","","",160,20);
TE.A(19,16,"Stacjonarne","index.php?m_id=174","","","",160,20);
TE.A(20,16,"Osprzęt","index.php?m_id=175","","","",160,20);
*/

TE.Get(16).arrIm = arrow_r;
TE.Get(16).arrIm1 = arrow_r;


TE.A(21,9,"Radiostacje wojskowe","index.php?m_id=3002","","","",160,20);
/*
TE.A(22,21,"Radiostacje","index.php?m_id=191","","","",160,20);
TE.A(23,21,"Osprzęt","index.php?m_id=192","","","",160,20);
*/

TE.Get(21).arrIm = arrow_r;
TE.Get(21).arrIm1 = arrow_r;

//TE.A(24,9,"Wypożyczenia","index.php?m_id=193","","","",160,20);
TE.A(25,9,"Montaż elektroniczny","index.php?m_id=194","","","",160,20);

//**************************************************************************************************
//                  Info
//**************************************************************************************************
TE.A(26,0,"Info","","","","",55,20);
TE.A(27,26,"Do pobrania","index.php?m_id=201","","","",110,20);
TE.A(28,26,"Biuletyn","index.php?m_id=202","","","",110,20);
TE.A(29,26,"Aktualności","index.php?m_id=44","","","",110,20);

TE.Get(26).arrIm = arrow_d;
TE.Get(26).arrIm1 = arrow_d;
TE.Get(26).bSize=1;
TE.Get(26).d=1;
TE.Get(26).fntColor=mmFont_color;
TE.Get(26).b=true;
TE.Get(27).b=true;
TE.Get(28).b=true;
TE.Get(29).b=true;

//**************************************************************************************************
//                 Targi, Linki, Sklepik
//**************************************************************************************************

TE.A(30,0,"Targi","index.php?m_id=300","","","",55,20);
TE.A(31,0,"Linki","index.php?m_id=401","","","",55,20);
//TE.A(32,0,"Sklepik","index.php?m_id=7","","","",55,20);
TE.A(33,0,"Klub ex R","index.php?m_id=6000","","","",80,20);

TE.Get(30).fntColor=mmFont_color;
TE.Get(30).width=40;
TE.Get(30).b=true;

TE.Get(31).fntColor=mmFont_color;
TE.Get(31).b=true;

//TE.Get(32).fntColor=mmFont_color;
//TE.Get(32).b=true;

TE.Get(33).fntColor=mmFont_color;
TE.Get(33).b=true;


//Here you can specify individual menu item properties
/*
TE.Get(1).bckColor="#a05030";TE.Get(1).selBckColor="#e0e0e0";
TE.Get(2).bckColor="#a05030";TE.Get(2).selBckColor="#e0e0e0";
TE.Get(3).fntColor="#ff0000";TE.Get(3).b=true;
TE.Get(4).bckColor="#a05030";TE.Get(4).selBckColor="#e0e0e0";
TE.Get(7).bckColor="#a05030";TE.Get(7).selBckColor="#e0e0e0";
TE.bSize=0;
TE.width=80;
TE.arrIm="";
*/

//writing menu into page
TE.WriteCSS();
TE.WriteDiv();
}
function MenuInit()
{
window.onresize= function(){window.history.go(0)};
TE.EventInit();//Initialising events
}
function Reset()
{
TE.Reset();//reseting menu
} 

