var ops = new Array(
new Array("sp","category","Subcategory"),
new Array(true,"searchPharma|Essential drugs","1|All"),
new Array(true,"searchPharma|Essential drugs","2|Contraceptives"),
new Array(true,"searchPharma|Essential drugs","3|Disinfectants"),
new Array(true,"searchPharma|Essential drugs","4|Drugs for inhalation"),
new Array(true,"searchPharma|Essential drugs","5|Eye preparations"),
new Array(true,"searchPharma|Essential drugs","6|Infusions"),
new Array(true,"searchPharma|Essential drugs","7|Injections"),
new Array(true,"searchPharma|Essential drugs","8|Susp., solutions & syrups"),
new Array(true,"searchPharma|Essential drugs","9|Skin preparations"),
new Array(true,"searchPharma|Essential drugs","10|Supp. & pessaries"),
new Array(true,"searchPharma|Essential drugs","11|Tablets & capsules"),

new Array(true,"searchMedDev|Medical devices","1|All"),
new Array(true,"searchMedDev|Medical devices","2|Blood bags"),
new Array(true,"searchMedDev|Medical devices","3|Catheters & tubes"),
new Array(true,"searchMedDev|Medical devices","4|Cold chain"),
new Array(true,"searchMedDev|Medical devices","5|Condoms"),
new Array(true,"searchMedDev|Medical devices","6|Diagnostic devices"),
new Array(true,"searchMedDev|Medical devices","7|Diagn. tests and strips"),
new Array(true,"searchMedDev|Medical devices","8|Dressings & bandages"),
new Array(true,"searchMedDev|Medical devices","9|General instruments"),
new Array(true,"searchMedDev|Medical devices","10|Gloves"),
new Array(true,"searchMedDev|Medical devices","11|Laboratory equipment"),
new Array(true,"searchMedDev|Medical devices","12|Laboratory supplies"),
new Array(true,"searchMedDev|Medical devices","13|Miscellaneous items"),
new Array(true,"searchMedDev|Medical devices","14|Mosq. nets & insectides"),
new Array(true,"searchMedDev|Medical devices","15|Surgical instruments"),
new Array(true,"searchMedDev|Medical devices","16|Suturing materials"),
new Array(true,"searchMedDev|Medical devices","17|Syringes & needles"),
new Array(true,"searchMedDev|Medical devices","18|Water purification materials"),
new Array(true,"searchMedDev|Medical devices","19|X-ray"),
new Array(true,"searchAIDS|HIV/AIDS","1|All"),
new Array(true,"searchAIDS|HIV/AIDS","2|First line ARV"),
new Array(true,"searchAIDS|HIV/AIDS","3|Second line ARV"),
new Array(true,"searchAIDS|HIV/AIDS","4|OI/STI drugs"),
new Array(true,"searchAIDS|HIV/AIDS","6|Condoms"),
new Array(true,"searchAIDS|HIV/AIDS","6|Diagnostic tests"),
new Array(true,"searchTB|Tuberculosis","1|All"),
new Array(true,"searchTB|Tuberculosis","2|First line drugs"),
new Array(true,"searchTB|Tuberculosis","3|Second line drugs"),
new Array(true,"searchTB|Tuberculosis","4|Miscellaneous"),					
new Array(true,"searchMalaria|Malaria","1|All"),
new Array(true,"searchMalaria|Malaria","2|ACT products"),
new Array(true,"searchMalaria|Malaria","3|Other anti-malaria products"),
new Array(true,"searchMalaria|Malaria","4|Mosq. nets & insecticides"),
new Array(true,"searchMalaria|Malaria","5|Diagnostic tests"),
new Array(true,"searchMK|Medical kits","83|Anaesthetic kit"),
new Array(true,"searchMK|Medical kits","84|Cholera kit"),
new Array(true,"searchMK|Medical kits","85|Chronic Disease kit"),
new Array(true,"searchMK|Medical kits","86|Epidemic Response kit"),
new Array(true,"searchMK|Medical kits","87|General Practitioner's kit"),
new Array(true,"searchMK|Medical kits","88|Hygiene kit"),
new Array(true,"searchMK|Medical kits","128|Insulin kit"),
new Array(true,"searchMK|Medical kits","202|Interagency Emergency Health kit"),
new Array(true,"searchMK|Medical kits","129|Intravenous Fluids kit"),
new Array(true,"searchMK|Medical kits","236|Male Circumcision kit"),
new Array(true,"searchMK|Medical kits","130|Mental hospital kit"),
new Array(true,"searchMK|Medical kits","131|Midwife kit"),
new Array(true,"searchMK|Medical kits","237|PEP kit"),
new Array(true,"searchMK|Medical kits","134|Reproductive Health kit"),
new Array(true,"searchMK|Medical kits","135|Transfusion kit"));



function FormSubmitProducts(){
var gotoPage;
gotoPage = '';
if (document.getElementById("category").value == 'searchPharma') gotoPage='/composite-36.htm';
if (document.getElementById("category").value == 'searchMedDev') gotoPage='/composite-37.htm';
if (document.getElementById("category").value == 'searchAIDS') gotoPage='/composite-38.htm';
if (document.getElementById("category").value == 'searchTB') gotoPage='/composite-39.htm';
if (document.getElementById("category").value == 'searchMalaria') gotoPage='/composite-35.htm';
if (document.getElementById("category").value == 'searchMK') gotoPage='/composite-82.htm';
if ((document.getElementById("category").value == 'searchMK') & (document.getElementById("Subcategory").value != ''))
{document.sp.action = '/composite-' + document.getElementById("Subcategory").value + '.htm';
}else{document.sp.action = gotoPage + "?searchText=" + document.getElementById("searchText").value; + "&amp;SubCategory=" + document.getElementById("SubCategory").value;
}
document.sp.submit();
return true;
}

function ContactSubmit()
{document.cd.submit();
return true;}

function update(e, dd)
{
	for (j=1; j < dd.length; j++)
	{
		dd[j][0] = true;
	}

	for (j=1; j < dd[0].length; j++)
	{
		for (i=1; i < dd.length; i++)
		{
			current = dd[i][j].split("|");
			value = current[0];
			choice = current[0];
			if (current.length == 2) choice = current[1];
			if (value != document[dd[0][0]][dd[0][j]][document[dd[0][0]][dd[0][j]].selectedIndex].value) dd[i][0] = false;
		}
		if (e == document[dd[0][0]][dd[0][j]])
		{
			dropdown(j+1,dd);
			for (k=j+2; k < dd[0].length; k++)
			{
				document[dd[0][0]][dd[0][k]].length = 0;
			}
			break;
		}
	}
}

function dropdown(item,dd)
{
	var pre1 = "";
	var j = 1;
	document[dd[0][0]][dd[0][item]].options.length = 0;
	document[dd[0][0]][dd[0][item]].options[0] = new Option('Select ' + dd[0][item], '');
	document[dd[0][0]][dd[0][item]].options[0].selected = true;
	for (i=1; i < dd.length; i++)
	{
		if (dd[i][0] || item == 1)
		{
			current = dd[i][item].split("|");
			value = current[0];
			choice = current[0];
			if (current.length == 2) choice = current[1];
			if (value != pre1)
			{
				var op = new Option(choice, value);
				document[dd[0][0]][dd[0][item]].options[j] = op;
				j++;
				pre1 = value;
			}
		}
	}
}



function fncOnLoad2(){
if (typeof(document.sp) != 'undefined')
dropdown(1,ops); 
}
