// используется

d = document;
function gebi(id) {
	return d.getElementById(id);
}

/*function setCookie(name, value) {
	var curCookie = name + "=" + escape(value) + ";expires=Sun, 31-Dec-34 23:59:59 GMT";
	if ((escape(value)).length <= 4000) document.cookie = curCookie+";";
} */

function setCookie(name, value, expires, path, domain, secure) {
	var curCookie = name + "=" + value +
	((expires) ? "; expires=" + expires.toGMTString() : "; expires=Sun, 31-Dec-34 23:59:59 GMT") +
	((path) ? "; path=" + path : "") +
	((domain) ? "; domain=" + domain : "") +
	((secure) ? "; secure" : "");
	document.cookie = curCookie;
}

function getCookie(name) {
	var prefix = name + "=";
	var cookieStartIndex = document.cookie.indexOf(prefix);
	if (cookieStartIndex == -1) return null;
	var cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length);
	if (cookieEndIndex == -1) cookieEndIndex = document.cookie.length;
	return unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex));
}

function absPosition(obj) {
	this.x = 0;
	this.y = 0;
    while(obj) {
		this.x += obj.offsetLeft;
		this.y += obj.offsetTop;
		obj = obj.offsetParent;
	}
	return {x:this.x,y:this.y};
}

/* jquery.dirty-clipboard.min.js */
(function(d){d.dirtyClipboard=function(e,g){if(e)d(g?g:document).mouseup(function(){var c,a,b,f;d("span.dirty-clipboard").remove();if(window.getSelection){c=window.getSelection();a=c.getRangeAt(0);b=a.cloneRange();b.collapse(false);f=d('<span class="dirty-clipboard">'+e+"</span>").css("position","absolute")[0];b.insertNode(f);a.setEndAfter(f);c.removeAllRanges();c.addRange(a)}else if(c=document.selection){a=c.createRange();b=a.duplicate();b.collapse(false);b.pasteHTML('<span class="dirty-clipboard" style="position: absolute;">'+ e+"</span>");a.setEndPoint("EndToEnd",b);a.select()}d("span.dirty-clipboard").css({overflow:"hidden",width:"1px",height:"1px"})})}})(jQuery);jQuery(function(){$.dirtyClipboard("<br><br>\u041f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435: <a href='"+location.href+"'>"+location.href+"</a>","#anons, #text")});
/* /jquery.dirty-clipboard.min.js */
