/*	addLoadEvent by Simon Willison	http://simon.incutio.com/archive/2004/05/26/addLoadEvent	** DEPRECATED **	* Just use code inside **/function addLoadEvent(func) {	Event.observe(window, 'load', func);}/** * window.toggleArea * Show/hide contentToHide and hide/show calledBy */function toggleArea(contentToHide, calledBy) {	if ($(contentToHide).style.display == 'none' | $(contentToHide).style.display == '') {		$(contentToHide).style.display = 'block';		$(calledBy).style.display = 'none';	} else {		$(contentToHide).style.display = 'none';		$(calledBy).style.display = 'inline';	}}Event.observe(window, 'load', function() {	COOKIEPROPERTIES = readCookie("youAreNumber");	if (COOKIEPROPERTIES == null) {		var randomSeed = Math.floor((Math.random() * 10000000000000));		var epochDate = new Date()		var seconds = epochDate.getTime();		var userID = String(randomSeed) + seconds;		createCookie("youAreNumber", userID, 365);	}});var dotIR = {	replaceElement: function(selector, colour, background, width, align, size, font, parentElement) {		var nodes = Selector.findChildElements(parentElement || document, [selector]);		nodes.each(function(node) {			// drop inside anchor if exists			if(node.firstChild.tagName && node.firstChild.tagName.toLowerCase() == 'a')				node = node.firstChild;			// skip replaced nodes			if(node.hasClassName('dotIR-replaced')) return;			node.addClassName('dotIR-replaced');			var lines = node.innerHTML.split(/<br *\/*>/i);			node.innerHTML = '';			lines.each(function(line) {				var params = {					t: line.strip().stripTags().unescapeHTML().replace(/&nbsp;/g, ' '),					w: width,					fc: colour,					bc: background,					align: align,					fs: size,					fn: font				}				var span = node.appendChild(new Element('span'));				span.appendChild(new Element('img', {					src: '/dotIR/IrImageHanler.ashx?' + $H(params).toQueryString(),					alt: line				}));			});		}, this);	}}function zopaIr(event) {	var baseColour;	var bodyClass = document.body.className;	if(bodyClass.indexOf('borrowing') != -1)  baseColour = '#f3cf03';	if(bodyClass.indexOf('lending') != -1)    baseColour = '#fa8100';	if(bodyClass.indexOf('about-zopa') != -1) baseColour = '#b7bc08';	if(bodyClass.indexOf('help') != -1)       baseColour = '#b7bc08';	if(bodyClass.indexOf('community') != -1)  baseColour = '#c70303';	if(bodyClass.indexOf('myzopa') != -1)     baseColour = '#2ba1df';	if(bodyClass.indexOf('promo') != -1)      baseColour = '#2ba1df';	dotIR.replaceElement ('body.borrowing legend.dotIR', '#B8B2A2', '#fff', 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('body.borrowing legend.dotIR', '#B8B2A2', '#fff', 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement('body.borrowing #prestitoHero h1.dotIR', '#fff', '#fba70d', 708, 'left', 36, 'AgBuch.ttf');	dotIR.replaceElement('body.borrowing #prestitoHero li', '#fff', '#f7bb08', 408, 'left', 20, 'AgBuch.ttf');	dotIR.replaceElement ('#hero h1.dotIR', '#fff', baseColour, 508, 'left', 36, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('#herobullets li', '#fff', baseColour, 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('h1.dotIR', baseColour, '#fff', 508, 'left', 36, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('h3.dotIR', '#b7b3a1', '#fff', 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('span.dotIR', '#b7b3a1', '#fff', 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('h2.dotIR', baseColour, '#fff', 508, 'left', 20, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('h5.dotIR', baseColour, '#fff', 508, 'left', 16, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('div.sectionHead h4.dotIR', '#ffffff', '#2ba1df', 408, 'left', 16, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('div.homeSectionHeader h4.dotIR', '#ffffff', '#b7b3a1', 408, 'left', 18, 'AgBuch.ttf', event.target);	dotIR.replaceElement ('div.sideBarHead h4.dotIR', '#ffffff', '#b7b3a1', 180, 'left', 16, 'AgBuch.ttf', event.target);};document.observe('document:contentLoaded', zopaIr);/** * Weird mehtods for hover images */function MM_swapImgRestore() { //v3.0	var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;}function MM_preloadImages() { //v3.0	var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();		var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)		if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}}function MM_findObj(n, d) { //v4.01	var p,i,x;	if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {		d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}	if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];	for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);	if(!x && d.getElementById) x=d.getElementById(n); return x;}function MM_swapImage() { //v3.0	var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)		if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}}