function swapImg(img, newpath)
{
	img.src = newpath;
}

function listSubCats(obj)
{
	var subCatObj = document.getElementById('sub_' + obj.id);
	var arrowImgObj = document.getElementById('img_' + obj.id);
	if (subCatObj.style.display == 'none')
	{
		subCatObj.style.display = 'block';
		swapImg(arrowImgObj, '../images/downarrow.gif');
	}
	else if(subCatObj.style.display == 'block')
	{
		subCatObj.style.display = 'none';
		swapImg(arrowImgObj, '../images/downarrow_opened.gif');
	}
}

