// This file encapsulates all necessary init functions for article pages.
USN.load('ads');
USN.load('printing');
USN.load('striping');
USN.load('socialBookmarking');
USN.load('analytics');
USN.load('analyticsExtensions');
USN.load('windows');
USN.load('technorati');
USN.load('gallery');
 
filterArticleID = function(str) {
	var IDFix = /id="article"/gi;
	var tD = str.replace(IDFix, '');
	return tD;
}


Event.observe(window, 'load', function() {
	// Related articles. See stripe.js
	stripe('more-related-articles');
	var headline = encodeURIComponent(document.title)
	// Social bookmarking. See shareLinks.js
	socialBookmarks = new shareGroup("share-controller");
	socialBookmarks.addShareSvcHandler("delicious","http://del.icio.us/post",626,436,'delicious','url','title');
	socialBookmarks.addShareSvcHandler("digg",'http://www.digg.com/submit',626,436,"digg",'phase=2&url','title');
	socialBookmarks.addShareSvcHandler("facebook","http://www.facebook.com/sharer.php",626,456,"facebook",'u','t');
	socialBookmarks.addShareSvcHandler("newsvine","http://www.newsvine.com/_wine/save",626,436,"newsvine",'u','h');
	socialBookmarks.addShareSvcHandler("reddit","http://reddit.com/submit",626,436,"reddit",'url','title');
	socialBookmarks.addShareContainer($("share-bottom"));
	socialBookmarks.addShareContainer($("share-top"));
	//technorati = new data("http://mp.technorati.com/220/roundup.xml", "html", "/usnews/general_ssi/scripts/libraries/technoratierror.htm", "article-technorati");
	//technorati.useFilter(filterArticleID);
	//technorati.registerPostProcessingFunction(function() { stripe('article-technorati'); });
	//technorati.acquire();
	
});


function poptastic(url)

{

	newwindow=window.open(url,'name','height=600,width=300,scrollbars=yes');

	if (window.focus) {newwindow.focus()}

}


