Thursday, May 3, 2012

Twitter updates in SharePoint 2010

In this article we will discuss how to show twitter updates in our SharePoint 2010 site.

For this first go to https://twitter.com/about/resources/widgets/widget_profile and in the customize section Give Twitter user name as well as you can also set preference like wether to include scroll or not, number of tweets to show etc.

Also you can set the appearance like background color, link color, tweets text color etc. Also you can set dimensions like width height etc.

Once set the above details then click on finish and grab code like below figure.


Now copy the code and paste it into a notepad file and save some where in the 14 hive directory. Here in this example I have stored inside the Styles folder like below.
C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\STYLES\myTwitterUpdates.txt


Also you can upload the text file to a document library.

After that add a content editor web part to the page. After that in the edit mode click on Add web part and from the Ribbon select the Media and Content web part category and select Content Editor web part and then click on Add as shown in the figure below.

Now go to the Content Editor web part properties. From the properties select Content Link and give path of the text file that content the javascript code. Since we have saved the file in the layouts folder the path will look like:
http://[Server Name]/_layouts/Styles/myTwitterUpdates.txt. Click on OK as shown in the figure below.

Then Save and Close the page, your Twitter updates will appear as shown in the figure below.

Also you can check some SharePoint 2010 articles here.

No comments:

Post a Comment