function sbOver(text) {
	if (text == '') {
		text = '...';
	} else {
		text=' '+text;
	}
	document.getElementById('sbText').innerHTML=text;
}

function sbDo(was) {
	var sburl=encodeURIComponent(window.location.protocol+'//'+(window.location.hostname+window.location.pathname).replace(/\/:.*?\//g, '/'));
	var sbtitle=encodeURIComponent(document.title + " - " + document.getElementById('mainimage').getAttribute('alt'));
	switch(was) {
		case 'digg':
			window.open('http://digg.com/submit?phase=2&amp;url='+sburl+'&title='+sbtitle);
			break;
		case 'delicious':
			window.open('http://del.icio.us/post?url='+sburl+'&title='+sbtitle);
			break;
		case 'wong':
			window.open('http://www.mister-wong.de/index.php?action=addurl&bm_url='+sburl+'&bm_description='+sbtitle);
			break;
		case 'yigg':
			window.open('http://yigg.de/neu?exturl='+sburl+'&exttitle='+sbtitle);
			break;
		case 'google':
			window.open('http://www.google.com/bookmarks/mark?op=add&hl=de&bkmk='+sburl+'&title='+sbtitle);
			break;
		case 'facebook':
			window.open('http://www.facebook.com/sharer.php?u='+sburl+'&t='+sbtitle);
			break;
	}
}
