Facebook "Recent Activity" from Asp.Net application -


i developing public website facebook login. once user has logged in facebook, want post website's url thumbnail facebook newsfeed "has read : url"

i new facebook integration. how can achieve asp.net application ? right now, have added 2 iframes , recent activity. able see post liked. how can post url read me ? thanks.

note : testing purpose have used www.yahoo.com in iframe.

below source code taken

http://www.abelski.com/courses/facebookplugins/abelski_facebook_plugins_page.html

<iframe src="http://www.facebook.com/plugins/activity.php?site=sg.news.yahoo.com&width=300&height=300&header=true&colorscheme=light&font=arial&recommendations=true" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:300px; height:300px;" allowtransparency="true"></iframe>  <iframe src="http://www.facebook.com/plugins/like.php?href=http%3a%2f%2fsg.news.yahoo.com&layout=standard&show_faces=true&width=450&action=like&colorscheme=light&height=80" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:80px;" allowtransparency="true"></iframe> 

you looking open graph action news.read action article object. need set application integrates this.

each of pages need have meta tags conforming article object defined

<html>     <head prefix="og: http://ogp.me/ns# fb: http://ogp.me/ns/fb#                    article: http://ogp.me/ns/article#">      <meta property="fb:app_id"               content="your_app_id">       <meta property="og:type"                 content="article">       <meta property="og:url"                  content="url of object">      <meta property="og:site_name"            content="name of site hosting article">      <meta property="og:image"                content="url image">      <meta property="og:title"                content="name of article">      <meta property="og:description"          content="description of object">       <meta property="article:published_time"  content="datetime">       <meta property="article:modified_time"   content="datetime">       <meta property="article:expiration_time" content="datetime">      <meta property="article:author"          content="url author object">      <meta property="article:section"         content="section of article">      <meta property="article:tag"             content="keyword">     </head> <body>     <!-- main article body --> </body> </html> 

and action in javascript need set

function postread()   {       fb.api(         '/me/news.reads',         'post',         { article: 'http://yoursite.com/articlepage.html' },         function(response) {            if (!response || response.error) {               alert('error occured');            } else {               alert('read successful! action id: ' + response.id);            }         });   } 

read more @ open graph tutorial


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -