sniffBrowsers();

var temp;

//menuItemBullet = new bulletPoint("../../../css/images/menu_off.gif","../../../css/images/menu_off.gif");

//labelBullet = new bulletPoint("../../../css/images/header_off.gif","../../../css/images/header_on.gif");

//subMenuBullet = new bulletPoint("../../../css/images/sub_header_off.gif","../../../css/images/sub_header_on.gif");


//code changed by Sheetal to display the geam menu in news archive and press archive pages 
if ((location.pathname=="/gepapp/Plastics/global/jsp/search/news_archive.jsp")|(location.pathname=="/gepapp/Plastics/global/jsp/search/press_archive.jsp"))
{
document.writeln('<SCRIPT language=JavaScript src="/gep/en/global/script/menu_GEAM_Home.js"> </SCRIPT>');
}

else
{
var m=300;

var m1=300;

var m2=350;
var l=350;

var n=400;

var n1=400;


var resinscount=0;

var lnpcount=0;
var foamcount=0;



var labelOutBor = '#FFFFFF';
var labelInBor = '#adafaf';
var labelOff = '#FFFFFF';
var labelOn = '#FFFFFF';
var itemOutBor = '#adafaf';
var itemInBor = '#FFFFFF';
var itemOff = '#FFFFFF';
var itemOn = '#FFFFFF';



function glossary()

 {

  window.open("/gepapp/controller?letterSelected=A",'Glossary',"resizable=1,width=600,height=550"); 

 }



//new menuBar(barName, barWidth, orientation, i_Bor, o_Bor, targetType) {

myTest = new menuBar('myTest',1000, 'horizontal', labelInBor, labelOutBor, 'self');

myTest.height = 2;

//myTest.addLabel(labelText, menuNo, offColour, onColour, labelURL, align) 

myTest.addLabel('Home',1, labelOff, labelOn, '/gep/Plastics/en/Home/Home/home.html', 'center');
myTest.addLabel('Datasheets', 2, labelOff, labelOn, '/gepapp/eng/datasheetinter/dswinter', 'center');
myTest.addLabel('Processing', 3, labelOff, labelOn, '/gep/Plastics/en/ProductsAndServices/ProcessLanding/processlanding.html', 'center');
myTest.addLabel('Industry Applications', 4, labelOff, labelOn, '/gep/Plastics/en/IndustryApplications/IndustryApplications/industry_applications.html', 'center');
myTest.addLabel('Engineering Data & Tools', 5, labelOff, labelOn, '/gep/Plastics/en/Tools/Tools/tools.html','center');
myTest.addLabel('Literature', 6, labelOff, labelOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp', 'center');
myTest.addLabel('Products & Services', 7, labelOff, labelOn, '/gep/Plastics/en/ProductsAndServices/ProductsAndServices/products_and_services.html', 'center');
myTest.addLabel('Build My Application ', 8, labelOff, labelOn, '/gepapp/Plastics/global/jsp/IdesTools/buildmyapp.jsp', 'center');



//Home

//menu(index, menuWidth, orientation, i_Bor, o_Bor)

menus[1] = new menu(1, 176, 'vertical', itemInBor, itemOutBor, 'self');
menus[1].height = 14;
menus[1].writeMenu();
 


//Datasheets

menus[2] = new menu(2, null, 'vertical', itemInBor, itemOutBor, 'self');

menus[2].height = 14;
menus[2].addItem('', null, itemOff, itemOn,'Vertical', 'left');
var patt1=/&#70;&#111;&#97;&#109;/g;

for(k=0;k<resinProducts.length;k++){
//alert("inside loop to add resins to the menu");
if(resinProducts[k].match(patt1)==null)
{
menus[2].addItem(resinProducts[k]+'* Resin', m, itemOff, itemOn, resinProductsLink[k], 'left');
}
else //it is a foam

{

temp= resinProducts[k];
    	
       templength=resinProducts[k].length;
      	len=temp.indexOf("&#32");
        firstpart=temp.substr(0,len);
     
        secondpart="* Foam";
        temp=firstpart.concat(secondpart);
     
        menus[2].addItem(temp,m, itemOff, itemOn, resinProductsLink[k], 'left');



}

m++;

}

resinscount=m;

/*for(k=0;k<foamProducts.length;k++){
//alert("inside loop to add foam to the menu");

//alert("foamproducts[l] is "+foamProducts[l]);

//
temp= foamProducts[k];
    	
       templength=foamProducts[k].length;
      	len=temp.indexOf("&#32");
        firstpart=temp.substr(0,len);
     
        secondpart="* Foam";
        temp=firstpart.concat(secondpart);
     
        menus[2].addItem(temp,l, itemOff, itemOn, foamProductsLink[k], 'left');
//

l++;

}*/

foamcount=l;


for(j=0;j<lnpProducts.length;j++){

lnpProducts[j]=lnpProducts[j].replace(/LNP/,"LNP*");	

//alert(lnpProducts[j]);

menus[2].addItem(lnpProducts[j]+'* Compound', n, itemOff, itemOn, lnpProductsLink[j], 'left');

n++;

}

lnpcount=n;

//alert(lnpcount);


menus[2].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[2].writeMenu();



//Processing

menus[3] = new menu(3, null, 'vertical', itemInBor, itemOutBor, 'self');
menus[3].height = 14;
menus[3].addItem('', null, itemOff, itemOn,'Vertical', 'left');
for(k=0;k<ProcessCollection.size();k++){
menus[3].addItem(ProcessCollection[k].getTitle(), null, itemOff, itemOn, ProcessCollection[k].getLink(), 'left');

}

menus[3].addItem('In Mold Decorating', null, itemOff, itemOn, '/gep/Plastics/en/ProductsAndServices/IMDHome/in_mold_decoration.html', 'left');

menus[3].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[3].writeMenu();



//Industry Applications

menus[4] = new menu(4, null, 'vertical', itemInBor, itemOutBor, 'self');

menus[4].height = 14;
menus[4].addItem('', null, itemOff, itemOn,'Vertical', 'left');

for(var z=0; z<FeaturedIndustryCollection.size(); z++){

menus[4].addItem(FeaturedIndustryCollection[z].getName(), null, itemOff, itemOn, FeaturedIndustryCollection[z].getLink(), 'left');

}

menus[4].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[4].writeMenu();



//Engineering Data & Tools

menus[5] = new menu(5, null, 'vertical', itemInBor, itemOutBor, 'new');

menus[5].height = 14;
menus[5].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[5].addItem('Data', null, itemOff, itemOn, null, 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Chemical Resistance', null, itemOff, itemOn, '/gepapp/eng/ccwinter/ccwinter', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Multipoint Engineering', null, itemOff, itemOn, '/gepapp/eng/eddinter/edd', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;SABIC Innovative Plastics Datasheets', null, itemOff, itemOn, '/gepapp/eng/datasheetinter/dswinter', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;External Supplier Datasheets', null, itemOff, itemOn, 'http://catalog.ides.com/MfrIndex.aspx?I=60955', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;External Supplier Material Selector', null, itemOff, itemOn, 'http://catalog.ides.com/PropertySearch.aspx?I=60955&PROPSET=Quick%2', 'left');



menus[5].addItem('', null, itemOff, itemOn, null, 'left');

menus[5].addItem('Tools', null, itemOff, itemOn, null, 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Automotive - LiteDesign', null, itemOff, itemOn, '/gepapp/eng/automotive_tools.jsp', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Automotive - SpecWizard', null, itemOff, itemOn, '/gepapp/eng/autospecinter/autospec', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Automotive - OEM Color Approval', null, itemOff, itemOn, '/gepapp/eng/acsinter/acs', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Engineering Tools', 9, itemOff, itemOn, '/webtools/', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Material Selection', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/IdesTools/ideslanding.jsp', 'left');

menus[5].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Build My Application', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/IdesTools/buildmyapp.jsp', 'left');



menus[5].height = 18;

//menus[5].addItem('Calendar Of Events', null, itemOff, itemOn, '/gep/en/NewsRoom/Events/events.html', 'left');

menus[5].addItem('eSeminars', null, itemOff, itemOn, '/gep/en/NewsRoom/Seminars/seminars.html', 'left');

menus[5].addItem('Glossary', null, itemOff, itemOn, '/gepapp/controller?letterSelected=A', 'left');

//menus[5].addItem('Web Seminars', null, itemOff, itemOn, '/gepapp/placeware/servlet/CalBuilder', 'left');

menus[5].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[5].writeMenu();



//Literature

menus[6] = new menu(6, null, 'vertical', itemInBor, itemOutBor, 'self');

menus[6].height = 14;
menus[6].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[6].addItem('Case Studies', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Case%20Study', 'left');

menus[6].addItem('Design Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Design%20Guide', 'left');

menus[6].addItem('Industry Brochure', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Industry%20Brochure', 'left');

menus[6].addItem('Marketing Brochures', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=%20Marketing%20Brochure', 'left');

menus[6].addItem('Material Properties Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=%20Material%20Properties%20Guide', 'left');

menus[6].addItem('Newsletter', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Newsletter', 'left');

menus[6].addItem('Processing Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Processing%20Guide', 'left');

menus[6].addItem('Product Brochure', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Product%20Brochure', 'left');

menus[6].addItem('Product Feature Sheet', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Product%20Feature%20Sheet', 'left');

menus[6].addItem('Product Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Product%20Guide', 'left');

menus[6].addItem('Product Selection Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=%20Product%20Selection%20Guide', 'left');

menus[6].addItem('Secondary Operations Guide', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=%20Secondary%20Operations%20Guide', 'left');

menus[6].addItem('Technical Paper', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/Literature/LiteratureAndTools.jsp?product=All&language=All&industryApplication=All&solutionArea=Resins&literatureType=Technical%20Paper', 'left');
menus[6].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[6].writeMenu();



//Products & Services

menus[7] = new menu(7, null, 'vertical', itemInBor, itemOutBor, 'self');

menus[7].height = 14;
menus[7].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[7].addItem('Resins & LNP Compounds',210, itemOff, itemOn, '/gep/Plastics/en/ProductsAndServices/ProductsAndServices/products_and_services.html', 'left');

menus[7].addItem('Specialty Film & Sheet', null, itemOff, itemOn, '/sfs/SFS/en/Product/ProductLandingPage/products.html', 'left');

menus[7].addItem('Color and Aesthetics', null, itemOff, itemOn, '/cxp/', 'left');

menus[7].addItem('Polymershapes', null, itemOff, itemOn, 'http://www.sabicpolymershapes.com/polyshapes/en/Home/Home/home.html', 'left');

menus[7].addItem("Specialty Additives and Intermediates", null, itemOff, itemOn, '/gep/en/ProductsAndServices/SpecialtyAdditivesandIntermediates/specialtyadditivesandintermediates.html', 'left');

menus[7].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[7].writeMenu();

 

//Build My Application

menus[8] = new menu(8, 179, 'vertical', itemInBor, itemOutBor, 'self');

menus[8].height = 14;
menus[8].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[8].addItem('Develop an Application', null, itemOff, itemOn, '/gepapp/Plastics/global/jsp/IdesTools/buildmyapp.jsp', 'left');

menus[8].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[8].writeMenu();





//Engineering Tools Submenu



menus[9] = new menu(9, null, 'vertical', itemInBor, itemOutBor, 'new');

menus[9].height = 12;
menus[9].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Assembly - Boss', null, itemOff, itemOn, '/webtools/redirect?tool=bosscalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Assembly - Snap-Fit Design', null, itemOff, itemOn, '/webtools/redirect?tool=snapfit', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Assembly - Thread Design Limit', null, itemOff, itemOn, '/webtools/redirect?tool=threadfailure', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Fatigue Prediction', null, itemOff, itemOn, '/webtools/redirect?tool=fatigueCalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Heat Transfer - large part', null, itemOff, itemOn, '/webtools/redirect?tool=therm', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Heat Transfer - mini part', null, itemOff, itemOn, '/webtools/redirect?tool=minitherm', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Stiffness - Beam', null, itemOff, itemOn, '/webtools/redirect?tool=beamcalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Stiffness - Cross-Flow', null, itemOff, itemOn, '/webtools/redirect?tool=crossflow', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Stiffness - Plate', null, itemOff, itemOn, '/webtools/redirect?tool=stiffnesscalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thermal Expansion/Stress Prediction', null, itemOff, itemOn, '/webtools/redirect?tool=thremalstress', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shear-Rate Prediction', null, itemOff, itemOn, '/webtools/redirect?tool=shearrate', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Flow Length Prediction', null, itemOff, itemOn, '/webtools/redirect?tool=flowcalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Part Weight Calculation', null, itemOff, itemOn, '/webtools/redirect?tool=weightcalc', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Tooling calculations', null, itemOff, itemOn, '/webtools/redirect?tool=toolingvolume', 'left');

menus[9].addItem('&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System Cost Estimator', null, itemOff, itemOn, '/webtools/redirect?tool=costEstimator', 'left');

menus[9].addItem('', null, itemOff, itemOn,'Vertical', 'left');
menus[9].writeMenu();



//Prod Serv Resins

menus[210] = new menu(210, null, 'vertical', itemInBor, itemOutBor, 'self');

menus[210].height = 12;
menus[210].addItem('', null, itemOff, itemOn,'Vertical', 'left');

for(k=0;k<resinProducts.length;k++)
{
//

if(resinProducts[k].match(patt1)==null)
{
menus[210].addItem(resinProducts[k]+'* Resin', null, itemOff, itemOn, resinProductsLink[k], 'left');
}
else //it is a foam

{
//alert("inside if not a foam");
temp= resinProducts[k];
    	//alert("resinsproducts[k] is "+resinProducts[k]);
       templength=resinProducts[k].length;
      	len=temp.indexOf("&#32");
        firstpart=temp.substr(0,len);
         //alert("firstpart is "+firstpart);
        secondpart="* Foam";
        temp=firstpart.concat(secondpart);
        //alert("temp is "+temp);
     
        menus[210].addItem(temp, null, itemOff, itemOn, resinProductsLink[k], 'left');



}


//


}
/*for(k=0;k<foamProducts.length;k++){

    	 temp = foamProducts[k];
    //	 alert("inside menu_geplastics temp is "+temp);
       templength=temp.length;
      	len=temp.indexOf("&#32");
        firstpart=temp.substr(0,len);
        //alert("inside menu_geplasticsfirstpart is "+firstpart);
        secondpart="* Foam";
        temp=firstpart.concat(secondpart);
       // alert("After concatenation temp is "+temp);

menus[210].addItem(temp, null, itemOff, itemOn, foamProductsLink[k], 'left');

}*/
for(k=0;k<lnpProducts.length;k++){



menus[210].addItem(lnpProducts[k]+'* Compound', null, itemOff, itemOn, lnpProductsLink[k], 'left');

}

menus[210].height = 20;

menus[210].addItem('Polymer Family', null, itemOff, itemOn, '/gep/Plastics/en/ProductsAndServices/PolymerTypes/polymer_types.html', 'left');
menus[210].addItem('', null, itemOff, itemOn,'Vertical', 'left');

menus[210].writeMenu();





//products series and family and line for datasheets



for(i=0;i<resinProducts.length;i++){

    var productname=resinProducts[i];
    //alert(productname);
    var productIndex=parseInt(product_lines[productname],10);
	  menus[m1] = new menu(m1, null, 'vertical', itemInBor, itemOutBor, 'self');
    menus[m1].height = 12;
    
    //menus[m1].addItem('', null, itemOff, itemOn,'Vertical', 'left');
    for(j=0;j<product_lines[productIndex]["family_n"].length;j++){	    	     
	       familyname = product_lines[productIndex]["family_n"][j];
	       familylink = product_lines[productIndex]["family_l"][j];
	       menus[m1].addItem(familyname, null, itemOff, itemOn,familylink, 'left');
    }
    for(k=0;k<product_lines[productIndex]["series_n"].length;k++){
          seriesname = product_lines[productIndex]["series_n"][k];
	        serieslink = product_lines[productIndex]["series_l"][k];
	        // alert(name);	        
          menus[m1].addItem(seriesname, null, itemOff, itemOn,serieslink, 'left');
    }
    var allproductlink="/gepapp/Plastics/servlet/ProductsAndServices/Product/series?sltPrdline="+productname+"&search=Search";
if(productname.match(patt1)==null)
{
var allproductname="All "+productname+"* Resins";
}
else {

  allproductname="All Ultem* Foam";

}
  
    menus[m1].addItem(allproductname, null, itemOff, itemOn,allproductlink, 'left');
    
    //menus[m1].addItem('', null, itemOff, itemOn,'Vertical', 'left');
    menus[m1].writeMenu();
   m1++;
}


/*for(i=0;i<foamProducts.length;i++){
    var productname=foamProducts[i];
    //alert(productname);
    var productIndex=parseInt(product_lines[productname],10);
	  menus[m2] = new menu(m2, null, 'vertical', itemInBor, itemOutBor, 'self');
    menus[m2].height = 12;
    for(j=0;j<product_lines[productIndex]["family_n"].length;j++){	    	     
	       familyname = product_lines[productIndex]["family_n"][j];
	       familylink = product_lines[productIndex]["family_l"][j];
	       menus[m2].addItem(familyname, null, itemOff, itemOn,familylink, 'left');
    }
    for(k=0;k<product_lines[productIndex]["series_n"].length;k++){
          seriesname = product_lines[productIndex]["series_n"][k];
	        serieslink = product_lines[productIndex]["series_l"][k];
	        // alert(name);	        
          menus[m2].addItem(seriesname, null, itemOff, itemOn,serieslink, 'left');
    }
    
    
    //
    
     temp = foamProducts[i];
    	 //alert("inside menu_geplastics temp is "+temp);
       templength=temp.length;
      	len=temp.indexOf("&#32");
        firstpart=temp.substr(0,len);
        //alert("inside menu_geplasticsfirstpart is "+firstpart);
        secondpart="* Foam";
        temp=firstpart.concat(secondpart);
       // alert("After concatenation temp is "+temp);
    //
    
    
    
    
    
    var allproductlink="/gepapp/Plastics/servlet/ProductsAndServices/Product/series?sltPrdline="+productname+"&search=Search";
    var allproductname="All "+temp+"s";
    //alert("allproductname is "+allproductname);
    menus[m2].addItem(allproductname, null, itemOff, itemOn,allproductlink, 'left');
    menus[m2].writeMenu();
//    alert("after writemenu function, m2 is "+m2);
   m2++;
}*/


for(i=0;i<lnpProducts.length;i++){
    var productname=lnpProducts[i].replace('*','');	
    var productIndex=parseInt(product_lines[productname],10);
//    alert(productIndex);
	  menus[n1] = new menu(n1, null, 'vertical', itemInBor, itemOutBor, 'self');
    menus[n1].height = 12;
    menus[n1].addItem('', null, itemOff, itemOn,'Vertical', 'left');
    for(j=0;j<product_lines[productIndex]["family_n"].length;j++){	    	     
	       familyname = product_lines[productIndex]["family_n"][j];
	       familylink = product_lines[productIndex]["family_l"][j];
         menus[n1].addItem(familyname, null, itemOff, itemOn,familylink, 'left');
    }
    for(k=0;k<product_lines[productIndex]["series_n"].length;k++){
          seriesname = product_lines[productIndex]["series_n"][k];
	        serieslink = product_lines[productIndex]["series_l"][k];
	        // alert(name);	        
          menus[n1].addItem(seriesname, null, itemOff, itemOn,serieslink, 'left');
    }
    var allproductlink="/gepapp/Plastics/servlet/ProductsAndServices/Product/series?sltPrdline="+productname+"&search=Search";
    var allproductname="All "+productname+"* Compounds";
    menus[n1].addItem(allproductname, null, itemOff, itemOn,allproductlink, 'left');
    
    menus[n1].addItem('', null, itemOff, itemOn,'Vertical', 'left');
    menus[n1].writeMenu();
    n1++;
}


menus[1].align='left';

menus[2].align='left';

menus[3].align='left';

menus[4].align='left';

menus[5].align='left';

menus[6].align='left';

menus[7].align='left';

menus[8].align='right';



menus[210].align='left';

//menus[350].align='left';



for(count=300;count<resinscount;count++){

  menus[count].align='right';

}


for(count=350;count<foamcount;count++){
//alert(" inside aligning foam menu");
  menus[count].align='right';

}

//

for(count=400;count<lnpcount;count++){

  menus[count].align='right';

}


}





