I'm writing an application for uploading the photos to the user's account from my application.
With following code i 'm succeeded of uploading the photo but still those photos doesn't directly uploads into the Album .
Album thumbnails shows empty album whereas detail page comes withe following warning .
Would you like to add these photos to your album?
The photos below were uploaded from another application, you'll need to approve them.
I want to avoid following instruction . Do I need to set any permission parameter in my Facebook app count ?
Thanks in advance !!
Related
I have a Facebook application in which a user can upload photos to a facebook fanpage. I am having trouble figuring out how to upload the photo as the user that is using the application. Currently I can have the fanpage upload the photo as itself, so the fanpage loses the author of the photo.
To do this I am grabbing the fan page's auth token(which I am assuming is the reason the app is posting as the fan page) and using that to pass to the "photos" method of the api. I am using the AS3 api, but I am sure the concept is the same no matter which api I am using.
var values:Object = {message:"message here", name:"title here"};
values.access_token = fanPageAccessToken;
values.image = file;
Facebook.api('fanPageId/photos/', handleUploadComplete, values,'POST');
When I change to the user's access token the image is uploaded to the user's photos. Even though I am specifying the fanPageId, it gets uploaded to the user's photos.
I am struggling here. Does anyone have an idea I can try, or some insight to share?
Thank you so much, I appreciate your time!
I've tried every possible API combination to post a photo to a page from the user, but it's no use. A user cannot post a photo to a page. Even creating an album on the page and then posting to that doesn't work.
When getting the "me/home" stream there is a difference between the photo objects i get in return. Some of them are returned with the source field (URL to the actual picture) and some not.
After investigating i learned that for photos uploaded to Facebook using the website itself there is the source and images fields in the object,
But for photos uploaded to Facebook by some kind of app (has the "application" field) there are no source/images fields, only a "link" field which direct me to the photo page (whole page, not just the photo)
Does that means i cant get the actual picture file for pics uploaded by apps ? am i missing something?
Update: The photos without the source field are "public".
You can use FQL to get very detailed information about the photo
SELECT src_big FROM photo WHERE pid='{photoId}'
For more information on what you can get from the FQL table see: http://developers.facebook.com/docs/reference/fql/photo/
Note: the quotes around the photo id is required as it is a string value
In my iphone app,I want to let the user upload an image to his facebook photo Album and publish a story at the same time.The story's media field contains the uploaded image's url.I successly uploaded the photo and got the result's "link" and "src_small" property.But when I use FBStreamDialog to publish the story,I got:
(source: sinaimg.cn)
At last,I find this:http://developers.facebook.com/live_status#msg_625,it says:
We no longer allow stream stories to contain images that are hosted on the fbcdn.net domain. The images associated with these URLs aren't always optimized for stream stories and occasionally resulted in errors, leading to a poor user experience. Make sure your stream attachments don't reference images with this domain. You should host the images locally.
It seems that I can't finish my job,What's your solution? thanks in advance!
you can't use that picture or the picture from facebook itself
you can upload the picture on other servers or upload it to online photo sharing like picasa
I got this functionality to work with ShareKit - it's really good:
http://www.getsharekit.com/
It's also open source, so you can see how they do it inside...
Good luck!
i have a image and i want to set this image as the users profile image. i came to know that we cannot upload directly to "Profile pictures" so i uploaded it in some other album and now i want to set this image as its profile pic ???
any idea how can i do that using fbconnect ?
thanks in advance
well i guess this is not possible...
http://developers.facebook.com/docs/reference/rest/photos.upload
3rd paragraph says:
You can upload to a specific user's album by calling photos.getAlbums. However, you cannot upload to a user's profile picture album.
Checkout my answer in this thread: how to set a facebook profile picture using the graph api
You can't set the profile picture, but you can upload it to an album, and then send the user to the "make profile picture"-page for that picture.
Is there any way to upload an image (UIImage) directly from an iPhone app to a user's wall/feed?
All the samples I see are either using a json-embedded link or they use the photos.upload call with album ID (aid) which results in the user getting the image in his photo album(s).
What I want to do is to upload an (UI)Image created (by the user) inside an iPhone app and upload to his/her wall. Is this possible? Sample code would be highly appreciated.
This isn't possible. To understand why, you have to consider the conceptual model that Facebook currently uses: Posts on a user's wall are just bits of text optionally attached to some link URL. That link URL can be some random image on the web, or it can just as well be an image that the user already has in their photo albums.
But a wall post cannot inherently "contain" an image in and of itself. Therefore you need to host the image somewhere, be it on your own site, or on Facebook itself, inside one of the user's albums by uploading it first to there.
I'm trying to figure out the same thing myself. One thing I did find out is that if you post the "Wall Photos" album they do get posted to the wall. However you only have a wall photos album if you've uploaded photos to your wall from your profile page before. And even then, you need to get the album aid and then post to it.
EDIT
Found a much better solution. First upload the photo to your default album, then make a post to the wall with the link to your photo that was returned when uploading (not a link to the image but the page the image is on).