function tabbing_skin_85189(super_cat_ids,super_titles,onclickcode)
{
	try {
		var defaultCity = "Auckland";		// ** the DEFAULT city ***
		
		// remove trailing spaces
		for(var i=0; i<super_titles.length;i++)
		{
			super_titles[i] = super_titles[i].trim();
		}
		
		var cities = new Array(); // set up a multi-dimensional array
		for(var i=0; i < super_cat_ids.length; i++)
		{
			cities[i] = {name: super_titles[i]}; //, id:super_cat_ids[i]};
		}
		cities.sort(function(a,b)
		{ 
				var x = a.name.toLowerCase();
				var y = b.name.toLowerCase();
				return ((x < y) ? -1 : ((x > y) ? 1 : 0));
		});
		var dropdown;
		dropdown = "<select id=\"cat_hl_85189_ddl\" onchange=\"this.id=this.options[this.selectedIndex].value;" + onclickcode + ";\">";
		if (super_cat_ids) 
		{
			for (var i=0;i<cities.length;i++) 
			{
				var id;
				var index;
				for(var j=0;j<super_titles.length;j++) 
				{
					if(super_titles[j] == cities[i].name) 
					{
						id = super_cat_ids[j];
						index = j;
					}
				}
				dropdown += "<option value=\"" + "link_" + index + "_" + id + "\" " + 
							(cities[i].name == defaultCity ? "selected=\"selected\"" : "") + ">" + 
							cities[i].name + 
							"</option>";
			}
		}
		dropdown += "</select>";
		return dropdown; 
	}
	catch(ex) 
	{
		alert(ex.description);
	}
}

String.prototype.trim = function() 
{
	return this.replace(/^\s+|\s+$/g,"");
};
String.prototype.ltrim = function() 
{
	return this.replace(/^\s+/,"");
};
String.prototype.rtrim = function() 
{
	return this.replace(/\s+$/,"");
};


function getOuterHTML(el)
{
	if(whichBrs() == "Internet Explorer")
	{
		return el.outerHTML;
	}
	else
	{
	    var span = document.createElement("span"); 
		span.appendChild(el.cloneNode(true));
	    return span.innerHTML;
	}
}

function setOuterHTML(el, html)
{
	if(whichBrs() == "Internet Explorer")
	{
		el.outerHTML = html;
	}
	else
	{
	    var range = document.createRange();
	    el.innerHTML = html;
	    range.selectNodeContents(el);
	    var frag = range.extractContents();
	    el.parentNode.insertBefore(frag, el);
	    el.parentNode.removeChild(el);
	}
}