﻿$.fn.extend({
	addPdfIcon: function(param)
	{
		var pdfElem = $(this);
		if(param == "after")
		{
			pdfElem.not(".noIcon").after("<span class='pdfAfter'>&nbsp;</span>");
		}
		else if (param == "before")
		{
			pdfElem.not(".noIcon").before("<span class='pdfBefore'>&nbsp;</span>");
		}
		pdfElem.click(function()
		{
			this.target = "_blank";
		});
	}
});
$.fn.extend({
	addExtIcon: function(param)
	{
		var extElem = $(this);
		if(param == "after")
		{
			extElem.not(".noIcon").not("a:has(img)").not(".buttonr_s a,.buttonr a,.buttonl_mov a").not("a[href*='.pdf']").after("<span class='extAfter'>&nbsp;</span>");
		}
		else if (param == "before")
		{
			extElem.not(".noIcon").not("a:has(img)").not(".buttonr_s a,.buttonr a,.buttonl_mov a").not("a[href*='.pdf']").before("<span class='extBefore'>&nbsp;</span>");
		}
	}
});

