function uknRelated() {

	// this._http = getHTTPObject(); // We create the HTTP Object
	this.containerBase = "resultRelatedContent";
	this.headerBase = "resultRelated";	
	this.linkClass = "subLink";
	this.captionShowRelatedArticles = "Show Related Articles";
	this.captionHideRelatedArticles = "Hide Related Articles";
	this.captionLoading = "Loading ...";
	this.captionNotFound = "<span style='color: #999'>No related articles found</span>";	
	this.relatedURL = "uknrelated.htm";

	this.showSim = function (simid, tagPostfix) {
	
		$("#" + this.containerBase+tagPostfix+simid).show();
		$("#" + this.headerBase+tagPostfix+simid).html( "<a href=\"javascript:ukn.hideSim("+ simid +",'"+ tagPostfix +"')\" CLASS=\"" + this.linkClass + "\">[" + this.captionHideRelatedArticles + "]</a>" );
	
	};
	
	this.hideSim = function (simid, tagPostfix) {
		
		$("#" + this.containerBase+tagPostfix+simid).hide();
		$("#" + this.headerBase+tagPostfix+simid).html( "<a href=\"javascript:ukn.showSim("+ simid +",'"+ tagPostfix +"')\" CLASS=\"" + this.linkClass + "\">[" + this.captionShowRelatedArticles + "]</a>" );
	
	};	
	
	this.loadSimDocs = function (query, tagPostfix, reference, db)  {
		this.simDocId = query;
		this.simTagPostFix = tagPostfix;

		$("#" + this.containerBase + tagPostfix + query).html( "<div class=\"errorBox\"><img src=\"/i/s4/ukn/ajax-loader.gif\" width=\"16\" height=\"16\">  " + this.captionLoading + "</div>" );
		
	$.get( url_base + this.relatedURL , { rid: query, ref: reference, c: db },
	  function(data){
	    if (data != "") {
			$("#" + ukn.containerBase + ukn.simTagPostFix + ukn.simDocId).html(data);
			$("#" + ukn.headerBase + ukn.simTagPostFix + ukn.simDocId).html( "<a href=\"javascript:ukn.hideSim("+ ukn.simDocId +",'"+ukn.simTagPostFix+"')\"  CLASS=\"" + ukn.linkClass + "\">[" + ukn.captionHideRelatedArticles + "]</a>" );
		} else {
			$("#" + ukn.containerBase + ukn.simTagPostFix + ukn.simDocId).html("");
			$("#" + ukn.headerBase+ukn.simTagPostFix+ukn.simDocId).html( ukn.captionNotFound  );
		}
	  });		
		
	}	
}

ukn = new uknRelated();
