i have a problem with og:image. Like i'm developing an facebook app and there is some steps in app. At last step user should share image that he/she created. But when i send url to created image to header for og:image, on share screen image can not be displayed. How can i solve this porblem? By the way i used debugger tool and there isn't any image either.
here is my debug link; http://corpusad.com/ecard/ecard/template_preview/64
Related
I'm new to PHP and I have developed a system that automatically applies a watermark to a manually uploaded image. What I want to do is have a user sign in with their Facebook account, have the PHP get their profile picture from graph.facebook.com and then save it on my server under the /images directory.
I've been trying to do this for the past 4 and a half hours but I have no idea what i'm doing. I've tried to use Facebook's User Picture SDK but i have no idea how to apply it (clearly just copying and pasting isn't going to work haha). If someone could please provide me with some code, you certainly be mentioned on the final page.
To show image in page
<img src="//graph.facebook.com/{{fid}}/picture">
To save
$image = file_get_contents('https://graph.facebook.com/'.$fid.'/picture?type=large');
$dir = dirname(__file__).'/avatar/'.$fid.'.jpg';
file_put_contents($dir, $image);
Facebook Graph API
http://graph.facebook.com/abdulla.nilam/picture
You can use graph API to get user's image
https://graph.facebook.com/v2.2/USER_ID/picture?width=500&height=500
USER_ID will be user's Facebook ID.
You can set the width and height as required.
I am having Google Play link(Android) and iTunes App Link(iTunes). I want to create a Facebook tab for my business page and on click of Facebook tab, my Google Play link can be opened.
I have registered myself on developers.facebook.com/apps and created a new App. Now Under Basic Info I get confused on what to enter the value for App Domains so I have entered play.google.com because my Google Play link starts with this.
Now under Page Tab, I have entered all the required information but entered probably the wrong value for Page Tab Edit URL . So I finally save my application but it is not working.
So now I have deleted my Page Tab section and I then switched over to App on Facebook section where under Canvas URL I have placed my Google Play URL with all the required details and then submitted for review.
Before I submit for the review finally it asked me that there should be no external URL used But I have used my Google Play URL in the Canvas URL section which is external.
I am completely confused now with this Facebook. I have also Googled a lot but with no result for me.
Please Guide me on integrating Android link(play.google.com) as Facebook Business Page tab.
Thanks !
I have solved this issue by using static iframe facebook application
What I did is simply created my desire page in HTML and placed it on my server and by static iframe facebook App, I called this page into IFrame.
Problem solved !
I made a web application in PHP that posts images to my Facebook pages.
Everything works if I'm online and press POST button.
Now what I wanted to do is:
upload image to my server
choose one of my Facebook pages
enter a message (text)
pick time I want the app to post this image to the chosen Facebook page (using RCON).
I know how to program those things but I fail when the script is called via RCON.
The script doesn't have access token so I can't post anything.
Is there any way how script can get access token to post images to my Facebook pages when I'm off with my friends?
Thank you.
I'm doing preliminary research for an upcoming project. Basically here is the user/data flow:
A webcam at an event takes pictures and sends the photos to a local server
A brand rep has an iPad with an app (developed as an HTML app saved to iPad home screen as an app). The app displays all photos from the local server as thumbnails via simple AJAX calls to load them into the view.
A user selects a photo. That photo will be sent from our local server to our remote server. The remote server will host a Facebook iFrame tab with the user selected photos.
At the same time, a link to the iFrame tab with a query string will be posted on the user's Facebook wall and Twitter (if they choose to authenticate of course).
Now the tricky part, we are 99% sure that the client is going to want to also upload the photo directly to the Facebook user's album. Possibly to TwitPic as well but that is a secondary concern. So my question is, is there a way to use PHP to upload a photo to a Facebook wall without using a typical html file input field and POST? Ideally, if we can do some kind of a file_get_contents on the photo URL from the local server and use PHP/FB API to upload the contents of the photo URL, we'd be in great shape.
The goal is to have the photo uploaded to the user wall with a caption like:
Check out my photo taken at _ event! [URL to client facebook tab with photo id].
#jeremyharris is right to say that Facebook's PHP SDK wraps cURL. You indeed need to use cURL to post a request to Facebook's API endpoint. Though, start by reading http://developers.facebook.com/docs/reference/api/ Publishing section to understand the mechanics before you jump onto their SDK.
Then familiarise with the feed object. You can use either it or the photo object to upload the photo.
We are developing a facebook iframe application that pulls some images (via an API) to the current user album (creates a new one).
The user views his newly uploaded album photos using a facebook lightbox clone. In this clone he must be able to comment and like the current viewed photo.
Is there a way to provide facebook comments & like to these pictures without the use of the Graph API (which would require us to replicate a lot of visuals).
Another try was the social plug-ins with the facebook photo url given but no success.
Any ideas?
I would recommend using the social plugins that facebook provide.
For the likes and comments you can specify a URL in the plugin code, that URL should be the URL of the photo relative to your app e.g. http://myapp.com/photo/123 and not the http://app.facebook.com address.
Facebook will need to be able to crawl that URL so if you are checking if the user is logged in via PHP then you should either disable this if the user agent contains facebookexternalhit or show a different page for that user agent. It doesn't matter about the content, just set a couple of og: meta tags and that should be fine.