Santry Enterprises posted on June 03, 2009 20:34

Have you seen those social bookmarks icons on weblogs now that allow your users to bookmark your blog entry on facebook, or some other social network? It is pretty easy to modify the DNN blog module to add that functionality. You can see an example of this on the blog module I customized on one of our FanGap.com network sites called
JonasBrothersFan.com.
First you need to go to
AddThis and sign up for an account so you can add the code to the ascx page on the DNN blog module. Once you complete the registration process on AddThis, you can get some client side code to paste into the DNN blog module.
Now that you signed up and have the code, find the ViewEntry.ascx page in the DesktopModules\Blog directory.
In the ViewEntry.ascx page you're going to paste the code within the ascx page so it looks something like the following:
<asp:label id="lblDateTime" cssclass="blog_date" runat="server"></asp:label>
<!-- ADDTHIS BUTTON BEGIN -->
<script type="text/javascript">
addthis_pub = 'fangap';
addthis_logo = 'http://fangap.com/portals/16/fangapscroller.gif';
addthis_logo_background = 'EFEFFF';
addthis_logo_color = '666699';
addthis_brand = 'FanGap.com';
addthis_options = 'favorites, email, digg, delicious, myspace, facebook, google, live, more';
</script>
<a href="http://www.addthis.com/bookmark.php"
onmouseover="return addthis_open(this, '', '[URL]', '[TITLE]')"
onmouseout="addthis_close()" onclick="return addthis_sendto()"><img
src="http://s9.addthis.com/button1-share.gif" width="125" height="16"
border="0" alt="" /></a>
<script type="text/javascript" src="http://s7.addthis.com/js/152/addthis_widget.js"></script>
<!-- ADDTHIS BUTTON END -->
<asp:hyperlink id="lnkRss" Runat="server"
ImageUrl="~/desktopmodules/Blog/Images/feed-icon-12x12.gif"
Target="_blank" resourcekey="lnkRss"></asp:hyperlink>
Then just save the page, and you should now have the icon in your page.