//$Id: bshare.js,v 1.3 2010/01/21 16:06:10 ghoffman Exp $
//$Source: /bbsrc/web/docs/en/jscommon/RCS/bshare.js,v $
//$Revision: 1.3 $

var StoryURL=location.href;
var StoryTitle=document.title;

function sharePop(url, width, height, name) {
	testwindow= window.open(url, name, "location=1,status=1,scrollbars=1,resizable=1,width=" + width + ",height=" + height);
}

function trimTools(strText) {
	return strText.replace(/\\./,"").replace("!","").replace(" ","");
}

function shareBusinessExchange() {
	sharePop('http://bx.businessweek.com/api/add-article-to-bx.tn?url='+encodeURIComponent(StoryURL), 850, 500, 'BusinessExchangePopup');
}

function shareTwitter() {
	sharePop('http://twitter.com/home?status='+encodeURIComponent(StoryURL), 850, 500, 'twitterPopup');
}

function shareDelicious() {
	sharePop('http://del.icio.us/post?v=2&url='+encodeURIComponent(StoryURL), 850, 500, 'deliciousPopup');
}

function shareDigg() {
	sharePop('http://digg.com/submit?url='+encodeURIComponent(StoryURL), 850, 500, 'diggPopup');
}

function shareFacebook() {
	sharePop('http://www.facebook.com/sharer.php?u='+encodeURIComponent(StoryURL), 850, 500, 'facebookPopup');
}

function shareLinkedIn() {
	sharePop('http://www.linkedin.com/shareArticle?mini=true&url='+encodeURIComponent(StoryURL), 850, 500, 'linkedinPopup');
}

function shareNewsvine() {
	sharePop('http://www.newsvine.com/_wine/save?popoff=1&h='+encodeURIComponent(StoryURL), 850, 445, 'newsvinePopup');
}

function shareProp() {
	sharePop('http://www.propeller.com/submit/?T='+encodeURIComponent(StoryURL), 850, 540, 'propPopup');
}

function shareYahoo() {
	sharePop('http://buzz.yahoo.com/buzz?targetUrl='+encodeURIComponent(StoryURL), 980, 540, 'yahooPopup');
}





