function wo(url, opt) {
	opt = opt || {};
	opt.url = url;
	/* width and height */
	opt.width = opt.width || 700;
	opt.height = opt.height || 500;
	/* bars */
	opt.status = opt.status || 'no';
	opt.toolbar = opt.toolbar || 'no';
	opt.location = opt.location || 'no';
	opt.menubar = opt.menubar || 'no';
	opt.directories = opt.directories || 'no';
	/* others */
	opt.resizable = opt.resizable || 'no';
	opt.scrollbars = opt.scrollbars || 'yes';
	opt.name = opt.name || '_blank';
	opt.top = opt.top || 20;
	opt.left = opt.left || 100;
	opt.channelmode = opt.channelmode || 0;
	/* open the window */
	window.open(opt.url, opt.name, 'width='+opt.width+', height='+opt.height+', status='+opt.status+', toolbar='+opt.toolbar+', location='+opt.location+', menubar='+opt.menubar+', directories='+opt.directories+', resizable='+opt.resizable+', scrollbars='+opt.scrollbars+', top='+opt.top+', left='+opt.left+', channelmode='+opt.channelmode);
	return false;
}


function write_flash(opt) {
	opt = opt || {};
	opt.url = opt.url || '';
	opt.width = opt.width || 0;
	opt.height = opt.height || 0;
	opt.wmode = opt.wmode || 'transparent';
	opt.flashVars = opt.flashVars || '';
	/* write it */
	document.write('<'+'object type="application/x-shockwave-flash" data="'+opt.url+'" width="'+opt.width+'" height="'+opt.height+'"'+'>');
	document.write('<'+'param name="movie" value="'+opt.url+'" '+'/'+'>');
	document.write('<'+'param name="allowScriptAccess" value="always" '+'/'+'>');
	document.write('<'+'param name="flashVars" value="'+opt.flashVars+'" '+'/'+'>');
	document.write('<'+'param name="wmode" value="'+opt.wmode+'" '+'/'+'>'+'<'+'/'+'object>');
	/*
	<object type="application/x-shockwave-flash" data="flash/but_top.swf" width="780" height="75">
	<param name="movie" value="flash/but_top.swf" />
	<param name="allowScriptAccess" value="sameDomain" />
	<param name="wmode" value="transparent"></object>
	*/
}


function showTab(care) {
	$('.cont').hide();
	$('#cont'+care).fadeIn();
	return false;
} function closeTab() {
	$('.cont').fadeOut();
	return false;
}


function tooltip() {
		xOffset = 10;
		yOffset = 20;		
	/* END CONFIG */		
	$('img').hover(function(e){											  
		this.t = this.title;
		if(this.t != '') {
			this.title = '';
			$('body').append('<p id="tooltip">'+ this.t +'</p>');
			$('#tooltip')
				.css('top',(e.pageY - xOffset) + 'px')
				.css('left',(e.pageX + yOffset) + 'px')
				.fadeIn('fast');
		}
    }, function(){
		this.title = this.t;
		if(this.title != '') $('#tooltip').remove();
    });
	$('img').mousemove(function(e){
		if($('#tooltip')) $('#tooltip')
			.css('top',(e.pageY - xOffset) + 'px')
			.css('left',(e.pageX + yOffset) + 'px');
	});			
};


