// JavaScript Document
var Bookmarks={
	d:'', viewFrmBookmarks:function(dN,eN) {
		SharingTools.gigyaSocialize();
},
	hideBookmarks:function() {
		$(Bookmarks.d).innerHTML=' '; 
		Bookmarks.d='';
		$('bookmarksFrm').removeClassName('current');
},

setBookmarks:function() {
	$('facebook').href='http://www.facebook.com/sharer.php?u=' + document.location;
	$('digg').href='http://digg.com/submit?url=' + document.location + '&amp;title=' + document.title.replace('blog.standforisrael - ','');
	$('delicious').href='http://del.icio.us/post?url=' + document.location + '&amp;title=' + document.title.replace('blog.standforisrael- ','');
	$('stumbleupon').href='http://www.stumbleupon.com/submit?url=' + document.location + '&amp;title=' + document.title.replace('blog.standforisrael - ','');
	$('reddit').href='http://reddit.com/submit?url=' + document.location + '&amp;title=' + document.title.replace('blog.standforisrael - ','');
	}
}

var SharingTools={
	showSocialSharing:function() {
		SharingTools.facebookLike();
	},

facebookLike:function() {
	$("#socialSharingTools").append('<div id="facebookLikeTool"><iframe scrolling="no" height="22" frameborder="0" width="110" src="http://www.facebook.com/plugins/like.php?href=' + encodeURIComponent(baseUrl + window.location.pathname.replace('comments.html','index.html')) + '&amp;layout=button_count&amp;show_faces=false&amp;width=200&amp;action=like&amp;font&amp;colorscheme=light&amp;height=21" allowTransparency="true"></iframe></div>');
},

tweetMeMe:function() {
	$("#socialSharingTools").html('<div id="tweetMeMeTool"><iframe scrolling="no" height="20" frameborder="0" width="90" src="http://api.tweetmeme.com/button.js?url=' + encodeURIComponent(baseUrl + window.location.pathname.replace('comments.html','index.html')) + '&amp;style=compact" allowTransparency="true"></iframe></div>');//&amp;source=standforisraelcom
},

gigyaSocialize:function() {
		$.getScript("http://cdn.gigya.com/JS/socialize.js",function() {
	
		var conf={ APIKey:'2_wcYtJX-Z07YGHw1oT0Aj_LQC76e1Sboyy2XZbS8skMHJc7Ami67UDBJCveFMiVCs' };
		var act=new gigya.services.socialize.UserAction();
		var baseUrl = 'http://blog.standforisrael.org';
		act.setUserMessage('');
		act.setTitle(document.title);
		act.setLinkBack(baseUrl + window.location.pathname + '?cid=share_gigyasocialize');
		act.setDescription(document.getElementsByName('description')[0].content);
		try {
		act.addMediaItem({
			type:'image',
			src:'http://blog.standforisrael.org' + document.getElementsByName('thumb')[0].content,
			href:baseUrl + window.location.pathname + '?cid=share_gigyasocialize'
		});
	} 

		catch (e) { };
		var params={
			userAction:act,
			disabledProviders:"linkedin, myspace",
			showMoreButton:"true"
		};

		gigya.services.socialize.showShareUI(conf,params);
		});
	}
}
