Upload one photo to Facebook fanpage - facebook

I'm using this tutorial http://pastebin.com/WpJmPYAi, and with some changes I can upload a photo to my fanpage.
But, I want to be able to upload when I'm logged out from Facebook. In my website, I need to be able to upload images to the fanpage without my account login.
Is this possible?
For example, I think: Is there any way to do this:
$page_info = $facebook->api("/".$fanpage."?fields=access_token");
Without a facebook accounts logged in, only with my app and accounts data.

You can set a stored access_token using the Facebook::setAccessToken($access_token) method.
See the PHP SDK documentation for details: https://developers.facebook.com/docs/reference/php/facebook-setAccessToken/

Related

Show Facebook user profile image to other users

I managed to implement Facebook login into my android app and it displays the public profile picture when I provide the access token in the link:
https://graph.facebook.com/{userId}/picture?type=large&access_token={ACCESS_TOKEN}
But what about the other users? It's a social media application and I want other users to see the profile picture as well.
Is this even possible after the changes Facebook made in September 2020?
I saw that Zynga Poker has exactly what I want, you sign up with Facebook and everyone else can see your profile picutre as well.
Can I somehow request from the user to give me the permission to use the profile picture piblicly?

Linking a website account to a facebook account so the user can post from the website anytime

I'm using the javascript API to link a website account to a users facebook account but I'm not sure if I'm doing it the best/easiest way.
I've created a facebook app
Used the FB.ui feed option to allow the user to post to their timeline
This works fine but the ui will ask the user to login each time they start a new session on the website. Have I missed something? Do I need to store and use the User Access Token?

Sharing an image link at the time of upload to facebook

For a variety of reasons I won't go into, I am unable to upload photos to a user's FB account from a standalone kiosk application.
As an alternative what I would like to try is
1- the user logs in to their FB account with name & password
2- the photo gets uploaded to one common admin account,
3- just the link to this uploaded photo gets posted to the user's feed.
So in essence there would be 2 login + uploads.
The first would be hidden from the user and have the hardcoded email+pw for the common admin account. The photo would be uploaded here.
The 2nd would be the one the user sees and would control just the posting of the link to the previously uploaded photo.
Can any facebook experts chime in and suggest whether this is possible?
I am using a local node.js,passport, express server to handle login and authentication.

Getting facebook profile while signup with facebook in liferay

I am trying to use the liferay inbuild facebook signin feature. By default facebook connect only stores first name,lastname,email and gender.
I want to get the profile picture of user from facebook and store in the database as userpotrait of a user when he sign up with facebook. How can do it in liferay?
You make the url for the profile picture of the user as -
http://graph.facebook.com/<USERID>/picture?type=normal
Try below URL to get facebook profile image.
http://graph.facebook.com/{your user name}/picture
You can easily get api for get this profile image for facebook also below link might help you.
Facebook API - How do I get a Facebook user's profile image through the Facebook API (without requiring the user to "Allow" the application)
For Store the image you will need to convert as a byte steam and store it using below Util class
UserServiceUtil.updatePortrait(long userId, byte[] bytes)
Hope this helps !

Uploading photos to facebook, Facebook App or Facebook Connect?

I am working on a website that allows people to upload photos to their facebook account (as if the user manually uploaded those photos to facebook), and the uploaded photos will be hosted on facebook instead of my server. Should I develop a facebook application or use facebook connect?
When you use facebook connect, you actually create a facebook application that will make it possible to "communicate" with facebook from your website.
You should know that a facebook application runs in facebook while facebook connect gives you the possibility to link whatever you have in your website to Facebook.
Though, I'm not sure if what you want to do is doable using the Facebook connect API.