Google+, Facebook and Twitter Widget

Topics: ASP.NET 2.0, Business Logic Layer, Controls, Themes
Feb 4, 2012 at 11:49 AM

Hi

Anyone know if there is a widget for blog posts for google+, Facebook like and Twitter tweets?

Thanks Alicia

 

Feb 4, 2012 at 3:00 PM
Edited Feb 4, 2012 at 3:03 PM

What about an extension ?

Alternatively, you could sign up to something like ShareThis

If you do, then paste this code into your theme's PostView.aspx where you would like the buttons to appear.

The code inside the script tags below is a lot better than what they will give you.

<div style="padding:5px 0;">

<span class='st_sharethis_hcount'></span>

<span class='st_fblike_hcount'>

</span> <span class='st_twitter_hcount'></span>

<span class="st_plusone_hcount"></span>

</div>                

<script type="text/javascript">

//<![CDATA[

$(document).ready(function () {

var switchTo5x = false;  

$.getScript("http://w.sharethis.com/button/buttons.js", function() {

stLight.options({ publisher: 'the publisher number they give you', onhover: 'false', doneScreen: 'false' });
});

});           

//]]>

</script>       

 
Feb 4, 2012 at 3:00 PM

Alicia,

The AddThis.NET extension looks good.

http://www.mbaldinger.com/post/AddThisNET-v2-for-BlogengineNET-released.aspx

Check out the BlogEngine.NET Gallery for a ton of fun stuff!

http://dnbegallery.org/cms/List/Extensions

Good luck,
Dave 

Feb 5, 2012 at 7:05 AM

Andy and Dave thanks for your tips!

Is this possible

Just need google+, facebook like and twitter tweet buttons without counters?

Thanks Alicia

 

 

Feb 5, 2012 at 10:49 AM

Hi Alicia, 

I haven't actually used any of the extensions but would be surprised if the option is not offered.

The code for the button line up you describe using ShareThis (various options available) is as follows:

<div>

<span class='st_plusone_large' displayText='Google +1'>

</span><span class='st_facebook_large' displayText='Facebook'>

</span><span class='st_twitter_large' displayText='Tweet'></span>

</div>

 

<script type="text/javascript">

//<![CDATA[

$(document).ready(function () {

//switchTo5x = true; //sets the popup style,  uncomment if you don't want the default. 

$.getScript("http://w.sharethis.com/button/buttons.js", function() {

stLight.options({ publisher: 'the publisher number they give you', onhover: 'false', doneScreen: 'false' });
});

});           

//]]>

</script>