Pages

Sunday, July 7, 2013

how to add facebook Invite Friends Link to your Blogger Site

1. Setp 1 How to Create Facebook App's

Finally, go to the Layout section of your Blogger dashboard and choose to add (or edit) an HTML/JavaScript gadget.
Paste the following code into your gadget, replacing the values highlighted in red and blue:
<script src="http://connect.facebook.net/en_US/all.js"></script>
<script>
FB.init({
appId:'your-app-id',
cookie:true,
status:true,
xfbml:true
});
function FacebookInviteFriends()
{
FB.ui({
method: 'apprequests',
message: 'Your Message Here'
});
}
</script>
<div id="fb-root"></div>
<span class="invite-friends-link"><a href='#' onclick="FacebookInviteFriends();">
Invite friends link text
</a></span>
<script type='text/javascript'>
if (top.location!= self.location)
{
top.location = self.location
}
</script>
And save the changes.

This will create a basic text link which your blog visitors can click to bring up a Facebook dialogue box in which their friends can be invited to visit your site.

Here's a demo of how the "Invite Facebook Friends" link works:
Invite friends to Blogger Buster

0 comments:

Post a Comment