function toggle(obj_name)
{
	name = obj_name.substr( 0, obj_name.lastIndexOf('_') );
	siz = obj_name.substr( obj_name.lastIndexOf('_') + 1 );

	obj = document.getElementById(obj_name);

	if (siz == 'big') siz2 = 'small'; else siz2 = 'big';
	obj2 = document.getElementById(name+'_'+siz2);
	obj.style.display = 'none';
	obj2.style.display = 'block';
}

function cache_img(src)
{
	var img = new Image();
	img.src = src;
}

function is_copy_to_clipboard_enabled()
{
	if(window.clipboardData)
	{
		return true;
	}
	return swfobject.hasFlashPlayerVersion('3');
}
function enable_copy_to_cliboard_links()
{
	if(is_copy_to_clipboard_enabled())
	{
		var coll = document.getElementsByTagName('a');
		for(i=0;i<coll.length;i++)
		{
			if(coll[i].className.indexOf('copy_to_clipboard') >= 0)
			{
				coll[i].style.display = 'inline';
			}
		}
	}
}
function copy_to_clipboard(text)
{
	if (window.clipboardData)
	{
		window.clipboardData.setData("Text",text);
	}
	else
	{
		if(!document.getElementById('copy_to_clipboard_flash'))
		{
			var divholder = document.createElement('div');
			divholder.id = 'copy_to_clipboard_flash';
			document.body.appendChild(divholder);
		}
		swfobject.embedSWF(http_static_path+'/flash/clipboard.swf', 'copy_to_clipboard_flash', '0', '0', '3', null, {clipboard:escape(text)});
	}
}