function createCookie(name,value,days) {
	if (days) {
		var date = new Date();
		date.setTime(date.getTime()+(days*24*60*60*1000));
		var expires = "; expires="+date.toGMTString();
	}
	else var expires = "";
	document.cookie = name+"="+value+expires+"; path=/";
}

function eraseCookie(name) {
	createCookie(name,"",-1);
}

function fontsize(direction) {
	var bodyTag = document.getElementById('outerWrap');
	var bodyFontSize = bodyTag.style.fontSize;
	

	if(direction == 'small') {
		bodyTag.style.fontSize = '77%';
	}
	else if(direction == 'large') {
		bodyTag.style.fontSize = '87%';
	}
	else if(direction == 'largest') {
		bodyTag.style.fontSize = '97%';
	}

	var nonce = Math.floor(Math.random() * 100);
	eraseCookie('jsFontSize');
	createCookie('jsFontSize', bodyTag.style.fontSize, '7');
}
