Monday, November 15, 2010

SharePoint "Like" button

Ever wondered what the users of your Intranet really like or don't like? Ever wanted your SharePoint 2007 site to be more "web 2.0"-ey? Well I've published this quick and dirty codeplex project that allows the addition of a "Like" button the any SharePoint List item page.

The project is available as a WSP, and source code.

It consists of two things - a Web Part that is the button that users click to "Like" or "Unlike" something, and a List Template that can be used to create a list to store who "Likes" an item.

The button has two ways of operating. If it finds a list that was built on the List Template included in the WSP, it allows each user to Like or Unlike an item as they see fit. The button uses the List it found to keep track of who likes a given item, and queries the list when it renders to determine which option should be presented. Along with the button, the web part also displays a brief message explaining how many people in total like the item being displayed.

The second mode of operating is to simply store a count of who many people click the Like button in the list item itself. This mode doesn't allow for a user to Unlike an item, because it doesn't know whether the user has Liked it already due to the absence of a list to store that information.

The codeplex project can be found here: SharePoint Facebook Like Button


  1. hello my name is Mario. I desperately need to figure out how to do this. I am currently using Sharepoint 2007. I would love it if you would be kind enough to follow up with me as I have a few questions. This would make me look like a hero at work.

    I know how to add the HTML code into Sharepoint but am unsure how to open/add a WSP file in. I tried renaming it as a .CAB file and no luck.Can you assist? I'd greatly appreciate it!

  2. hi I have a slight requirement change. Where in i am trying to capture the title and url of hte list item. could you plese share your code so that i can try to modify it. I could not find the code behind with the wsp file