[Facebook Flash Graph API]How to get PID from the POST result
I am using Graph API to upload photo to the facebook via flash application. I am able to upload it but what I am trying to do is to get pid of the photo I have uploaded.
Facebook.api('/me/photos', handleUploadComplete, values,'POST');
This is the code that im using and once 'POST' is done, I know that it returns results to 'handleUploadComple开发者_Python百科te' function. how can i get the pid from that result?
please help.
The 'pid' is part of the legacy/being deprecated REST api. Since you're using the Graph API, the id you're receiving is not a REST pid.
What you'll have to do is use the delegate function to make another request, using the REST api, to locate your photo in the album you've uploaded it. Then, using another REST FQL call, query the photo you just uploaded and retrieve, that way, the pid.
精彩评论