	function tc (id, openicon) {
		if ($(id) !== undefined) {
			$(id).toggle();
			if (openicon !== undefined) {
				if ($(id).visible()) {
					$(openicon).update(' - ')
				}
				
				else {
					$(openicon).update(' + ');
				}
			}
		}
		return false;
	}
	
	function sod (target, toggle, reload, dwidth, dheight) {
		if (toggle == true) {
			if ($('togglecoverscreen') == undefined) {
				if (dwidth == undefined) {
					var setLeft = '30%';
					var swidth = '350';
				}
				
				else {
					var setLeft = '15%';
					var swidth = dwidth;
				}
				
				if (dheight == undefined) {
					var setTop = '30%';
					var sheight = '300';
				}
				
				else {
					var setTop = '15%';
					var sheight = dheight;
				}
				
				var filler = document.createElement('div');
				document.body.appendChild(filler);
				filler = $(filler);
				filler.id = 'togglecoverscreen';
				filler.onclick = function () { $('togglecoverscreen').remove(); $('togglecontainer').remove()}
				filler.setStyle({ width: '100%', height: '100%', position: 'fixed', left: '0px', top: '0px', backgroundColor: '#000', zIndex: '10'});
				filler.setOpacity(0.8);
				var container = document.createElement('div');
				container = $(container);
				container.id = 'togglecontainer';
				document.body.appendChild(container);
				container.setStyle({ position: 'fixed', left: setLeft, top: setTop, backgroundColor: '#FFF', zIndex: '15', padding: '10px'});
				container.innerHTML = '<iframe src="'+target+'" style="border: 0px solid #FFF; width: '+swidth+'px; height: '+sheight+'px;"></iframe>';
			}
		}
		
		else {	
			if (reload !== undefined) {
				if (top.window.location.search+top.window.location.hash == reload) {
					top.window.location.reload();
				}
				
				else {
					top.window.location.replace(reload);
				}
			}
			
			if (top.$('togglecoverscreen') !== undefined) {
				top.$('togglecoverscreen').remove(); top.$('togglecontainer').remove()
			}
		}
	}
	
	function loadTiny(type) {
		if (type == 'guestbook') {		
			tinyMCE.init({
				mode : "textareas",
				theme : "advanced",
				plugins : "inlinepopups",
				theme_advanced_buttons1 : "bold,italic,separator,strikethrough,bullist,numlist,undo,redo,link,unlink",
				theme_advanced_buttons2 : "",
				theme_advanced_buttons3 : "",
				theme_advanced_toolbar_location : "top",
				theme_advanced_toolbar_align : "left",
				theme_advanced_statusbar_location : "none",
				theme_advanced_path : false,
				convert_newlines_to_brs : true,
				skin : "o2k7",
				skin_variant : "black",
			  
				content_css : "styles/generic.css?" + new Date().getTime()
			});
		}
		
		else {
			tinyMCE.init({
				mode : "textareas",
				theme : "advanced",
				plugins : "inlinepopups",
				theme_advanced_buttons1 : "image,fontselect,fontsizeselect,,|,forecolor,|,bold,italic,strikethrough,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,undo,redo,link,unlink",
				theme_advanced_buttons2 : "",
				theme_advanced_buttons3 : "",
				theme_advanced_toolbar_location : "top",
				theme_advanced_toolbar_align : "left",
				theme_advanced_statusbar_location : "none",
				theme_advanced_path : false,
				convert_newlines_to_brs : true,
				skin : "o2k7",
				skin_variant : "black",
			  
				content_css : "styles/generic.css?" + new Date().getTime()
			});
		}
	}
