$(document).ready(function() {
	var cookie = $.cookie('__utmv');

	$("body").append("<div id='statExternalLinks' style='display:none'>" + 
			// WEB2.0 USERS
				 "<a href='http://del.icio.us/'>delicious</a>" + 
				 "<a href='http://docs.google.com/'>googledocs</a>" +
				 "<a href='http://www.digg.com/'>digg</a>" + 
				 "<a href='http://www.stumbleupon.com/'>stumbleupon</a>" + 
				 "<a href='http://www.twitter.com/'>twitter</a>" + 
			// COMMUNITY USERS
				 "<a href='http://www.facebook.com/'>facebook</a>" + 
				 "<a href='http://www.myspace.com/'>myspace</a>" + 
				 "<a href='http://www.secondlife.com/'>secondlife</a>" +
			// CREATIONIST GROUPIES
				 "<a href='http://www.icr.org/'>icr</a>" + 
				 "<a href='http://www.drdino.com/'>drdino</a>" + 
				 "<a href='http://creationontheweb.com/'>cmi</a>" + 
				 "<a href='http://creationresearch.org/'>crsq</a>" + 
			// EVOLUTION NEWS FOLLOWERS
				 "<a href='http://www.newscientist.com/'>newscientist</a>" + 
				 "<a href='http://www.sciam.com/'>sciam</a>" + 
				 "<a href='http://scienceblogs.com/'>scienceblogs</a>" + 
				 "<a href='http://scienceblogs.com/pharyngula/'>pzmeyer</a>" + 
				 "<a href='http://www.talkorigins.org/'>talkorigins</a>" + 
				 "<a href='http://www.richarddawkins.net/'>dawkins</a>" + 
				 "<a href='http://www.ncseweb.org/'>ncse</a>" + 
			// ID FOLLOWERS
				 "<a href='http://www.uncommondescent.com/'>uncommondescent</a>" +
				 "<a href='http://www.evolutionnews.org/'>evonews</a>" + 
			// MEDIA JUNKIES
				 "<a href='http://www.youtube.com/'>youtube</a>" + 
				 "<a href='http://www.godtube.com/'>godtube</a>" +
				 "<a href='http://www.flickr.com/'>flickr</a>" +
				 "<a href='http://picasaweb.google.com/home'>picasa</a>" +
				 "<a href='http://www.vimeo.com/'>vimeo</a>" +
				 "<a href='http://www.hulu.com/'>hulu</a>" +
				 "<a href='http://www.apple.com/trailers'>movietrailers</a>" +
			// ONLINE SHOPPERS
				 "<a href='http://www.amazon.com/'>amazon</a>" +
				 "<a href='http://www.ebay.com/'>ebay</a>" +
				 "<a href='http://www.craigslist.org/'>craigslist</a>" +
				 "<a href='http://www.barnesandnoble.com/'>barnesnoble</a>" +
				 "<a href='http://www.walmart.com/'>walmart</a>" +
				 "<a href='http://www.target.com/'>target</a>" +
			// "CHRISTIAN" USERS
				 "<a href='http://www.gty.org/'>macarthur</a>" +
				 "<a href='http://www.sermonaudio.com/'>sermonaudio</a>" +
				 "<a href='http://www.christiananswers.net/'>christiananswers</a>" +
				 "<a href='http://www.biblegateway.com/'>biblegateway</a>" +
				 "<a href='http://www.focusonthefamily.com/'>focus</a>" +
				 "<a href='http://www.pluggedinonline.com/'>pluggedin</a>" +
				 "<a href='http://www.coralridge.org/'>coralridge</a>" +
				 "<a href='http://www.crosswalk.com/'>crosswalk</a>" +
				 "<a href='http://www.oneplace.com/'>oneplace</a>" +
				 "<a href='http://www.visionforum.com/'>visionforum</a>" +
				 "<a href='http://www.christianitytoday.com/'>ct</a>" +
				 "<a href='http://www.castingcrowns.com/'>castingcrowns</a>" +
			// KIDS USERS
				 "<a href='http://www.webkinz.com/us_en/'>webkinz</a>" +
				 "<a href='http://www.bigideafun.com/'>veggietales</a>" +
				 "<a href='http://www.cartoonnetwork.com/'>cartoonnetwork</a>" +
				 "<a href='http://www.qubo.com/'>qubo</a>" +
				 "<a href='http://www.lego.com/'>lego</a>" +
				 "<a href='http://mln.lego.com/en-us/privateview/default.aspx'>mylego</a>" +
				 "<a href='http://disney.go.com/index'>disney</a>" +
				 "<a href='http://disney.go.com/mypage/'>mydisney</a>" +
				 "<a href='http://www.clubhousemagazine.com/'>clubhouse</a>" +
				 "<a href='http://www.whitsend.org/'>whitsend</a>" +
				 "<a href='http://www.cbhministries.org/home.php'>cbh</a>" +
				 "<a href='http://kids4truth.com/'>kids4truth</a>" +
			// OTHER
				 "<a href='http://www.creationmuseum.org/'>museum</a>" + 
				 "<a href='http://www.wired.com/'>wired</a>" + 
				 "<a href='http://en.wikipedia.org/'>wikipedia</a>" + 
				 "<a href='http://www.joelosteen.com/'>joelosteen</a>" + 
				 "<a href='http://www.beliefnet.com/'>beliefnet</a>" + 
				 "</div>");

	
		var userVars = '';
		if (cookie != undefined) userVars = cookie.split(".")[1];
		
		$("#statExternalLinks a").each(function() {
			var curSite = $(this).text();
			var color = $(this).css("color");
			if (userVars.indexOf(curSite) == -1 &&
				(color == "rgb(130, 129, 207)" || 
				color == "#8281CF" ||
				color == "#8281cf")) {
				
				if (userVars.length > 0) userVars += "|";
				userVars += curSite;
				
			}
		});
		$("#statExternalLinks").remove();
		pageTracker._setVar(userVars);
});