Click here to Skip to main content
15,893,904 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am having a gridview in asp.net which binds the selected values from db..
i would like to add fb share button for each row at the end of the row

help me in this....
Posted
Comments
Herman<T>.Instance 14-Mar-12 8:10am    
what have you tried?
[no name] 14-Mar-12 8:11am    
What problem are you having? Adding the button? Or connecting to Facebook?
idhris2011 14-Mar-12 8:17am    
Adding the button

1 solution

Add on the page:
JavaScript
<script src="http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php" type="text/javascript"> </script>  

 <script type="text/javascript">
       FB_RequireFeatures(["XFBML"], function() {
       FB.Facebook.init("<sec code>", "xd_receiver.htm");
    });
    function logoutfb()
    {
    FB.Connect.logout();    
    }
</script> 

Now you can use it as your button in gridView:
C#
<fb:login-button length="long"  önlogin="window.location='abc.aspx'"></fb:login-button>
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900