facebook-opengraph

Using OpenGraph with PHP (cUrl requests for actions)

久未见 提交于 2019-12-03 07:30:57
I created an app for my website, set action (read) and object (article), and placed the objects code (META tags in the head) at the article page on my website. Now, I want to know how to send a cUrl request whenever a user reads an article on my website, so it'll feature on his wall. When I press the "get code" link near the action, that's what I get: curl -F 'access_token=***' \ -F 'article=http://example.com' \ 'https://graph.facebook.com/me/yellowheart:read' (There's an actual access token of course). Now, how do I make it happen? Daniel. Using the PHP SDK you would use the api method.

Jquery Select meta[property=og:image]?

和自甴很熟 提交于 2019-12-03 06:32:33
问题 I want to select in Jquery the main photo in a web page, I just have the url page. so I decided to use the meta written for Facebook sharing. I want to select the content of : meta property="og:image" content="http://blablabla.jpg" I wrote this, but it doesn't work: $("meta[property=og:image]").attr("content"); Any ideas ? Thank you 回答1: $('meta[property="og:image"]').attr('content') http://jsfiddle.net/ZxmCw/ 回答2: :image is parsed as a pseudo-selector. I think you need quotes around "og

Extend Facebook Open Graph Token For Posting to Pages

荒凉一梦 提交于 2019-12-03 05:10:48
I'm using this tutorial (from the first answer on that page). In short it uses a FB app, and PHP CURL GET to post to your Facebook page via HTTP. I have it working and can post to my page (as my page) with the correct token. However, the page access token only lasts an hour, meaning you have to constantly re-authorize by generating a new token. How can I set-and-forget, or otherwise extend my token? I have read the facebook documentation but can't apply it to my scenario. I just want to authorise once, receive a token and have my web form be able to post to my page. You get your page access

OG:type article vs website for Individual Web Pages That Are Not Articles

為{幸葍}努か 提交于 2019-12-03 01:14:40
I'm seeking clarification regarding the use of og:type article vs website for an individual web page that is technically not an "article" but also does not represent an entire website. Documentation seems contradictory: From https://developers.facebook.com/docs/opengraphprotocol/#types Use article for any URL that represents transient content - such as a news article, blog post, photo, video, etc. Do not use website for this purpose. website and blog are designed to represent an entire site, an og:type tag with types website or blog should usually only appear on the root of a domain. In this

og:image ignored when sharing link, although accepted in linter

与世无争的帅哥 提交于 2019-12-02 22:22:21
问题 I want to share a link to my own website on Facebook, so I added the necessary og: tags to the <head> section. Checked it in the linter, and it displays everything I want it to display. When I actually want to share it in the newsfeed (as in copy and paste the link into the status formular), the image is ignored. Here's a sample link: http://iamschulz.de/video/4 回答1: Does it break the image size requirements? If so it'll still be detected by the debug tool, but won't actually be rendered in

facebook og:image does not fetch image from php file that echoes the URL

孤者浪人 提交于 2019-12-02 21:54:33
问题 facebook OG fetch image from echoed URL, is this possible? since I included a php file that will echo the image URL but when I check in Sharing debugger the content is empty <meta property="og:image" content="" /> my meta tag : <meta property="og:image" content ="<?php include "meta_gambar.php"?>"> and the php file : <?php $module=$_GET['module']; $id=$_GET['id']; if($module=='detailproduk'){ //prepare query $stmt=mysqli_prepare($con,"SELECT gambar FROM produk WHERE id_produk=?"); if($stmt==

Jquery Select meta[property=og:image]?

独自空忆成欢 提交于 2019-12-02 20:12:33
I want to select in Jquery the main photo in a web page, I just have the url page. so I decided to use the meta written for Facebook sharing. I want to select the content of : meta property="og:image" content="http://blablabla.jpg" I wrote this, but it doesn't work: $("meta[property=og:image]").attr("content"); Any ideas ? Thank you $('meta[property="og:image"]').attr('content') http://jsfiddle.net/ZxmCw/ :image is parsed as a pseudo-selector. I think you need quotes around "og:image" 来源: https://stackoverflow.com/questions/8977652/jquery-select-metaproperty-ogimage

Use Facebook API with Objective C to find random Facebook user image

自闭症网瘾萝莉.ら 提交于 2019-12-02 19:41:08
问题 I am building an app that returns a random Facebook profile picture. So far I have the code below generating a random profile ID which sometimes does return a real profile but sometimes doesnt and just shows the generic blue Facebook face. When I use the given number on the actual website graph API it just returns false. My question is how would I put the code in so that if the random number generated returns a false profile, it just keeps generating a new random number until a real profile

facebook reset cache on “Share on Facebook” links

淺唱寂寞╮ 提交于 2019-12-02 16:29:33
问题 I just updated our site's <meta> 's open graph protocol. I just noticed that whenever I share some links, the old <meta> is the one being parsed by Facebook. However, to those links I run on debugger tool they show the updated <meta> . Is there a way to have Facebook recognized updated <meta> on all links aside from pasting it on debugger? 回答1: When You update your <meta> ( Open graph ) tags and run it through the debugger You are updating and clearing Facebook servers cache , Not Yours!

Javascript Facebook share dialog with open graph “og:url” not working

本小妞迷上赌 提交于 2019-12-02 11:47:53
问题 I am currently using the javascript Facebook share dialog API version 3.2 as follows: FB.ui( { method: "share_open_graph", action_type: "og.likes", action_properties: { object: { "og:title": "Test Title", "og:description": "Test description here", "og:image": "https://url-to-image-here", "og:url": "https://google.com" } } }, (fbResponse: any) => { // handle response here. } ); When i include the og:url with a non-empty value, I keep getting the following response when the dialog loads