2013-03-20 2 views
5

Facebook SDK 3.1.1을 사용하여 Facebook에서 비디오를 공유하고 있습니다. 여기에 코드를 언급했습니다.Facebook에서 비디오 공유가 실패했습니다.

FBRequestConnection *newConnection = [[FBRequestConnection alloc] init]; 

    // for each fbid in the array, we create a request object to fetch 
    // the profile, along with a handler to respond to the results of the request 
    NSString *fbid = @"me"; 
    // create a handler block to handle the results of the request for fbid's profile 
    FBRequestHandler handler = 
    ^(FBRequestConnection *connection, id result, NSError *error) { 
     // output the results of the request 
     [self requestCompleted:connection forFbID:fbid result:result error:error]; 
    }; 

    // create the request object, using the fbid as the graph path 
    // as an alternative the request* static methods of the FBRequest class could 
    // be used to fetch common requests, such as /me and /me/friends 

    NSData *videoData = [NSData dataWithContentsOfFile:path]; 
    NSMutableDictionary *params = [NSMutableDictionary dictionaryWithObjectsAndKeys: 
            videoData, @"video.mov", 
            @"video/quicktime", @"contentType", 
            @"Video", @"title", 
            @"Video Test Description", @"description", 
            @"hello",@"subdescription", 
            nil]; 
    FBRequest *request = [[FBRequest alloc] initWithSession:theDelegate.session graphPath:@"me/videos" parameters:params HTTPMethod:@"POST"]; 
    //:FBSession.activeSession graphPath:@"me/?fields=location"]; 

    // add the request to the connection object, if more than one request is added 
    // the connection object will compose the requests as a batch request; whether or 
    // not the request is a batch or a singleton, the handler behavior is the same, 
    // allowing the application to be dynamic in regards to whether a single or multiple 
    // requests are occuring 
    [newConnection addRequest:request completionHandler:handler]; 

    // if there's an outstanding connection, just cancel 
    [self.requestConnection cancel]; 

    // keep track of our connection, and start it 
    self.requestConnection = newConnection; 
    [newConnection start]; 

이전에 제대로 작동하고있었습니다. 업로드 동영상 요청을 시작할 때마다 응답으로 공유 된 동영상 ID가 표시됩니다. 그러나 FB에서 내 프로필을 확인할 때 다음 메시지가 계속 표시됩니다. 동영상을 처리 할 수 ​​없습니다. 일반적인 문제에 대해 알아 보려면 비디오 도움말 페이지를 방문하십시오.

다른 AppIds로 시도했습니다. 동영상 업로드는 페이스 북 웹 사이트를 사용하여 업로드 할 때 작동합니다. 이걸 도와주세요. 그것은 급해.

미리 감사드립니다.

+2

당신이 – Khushboo

+2

예 내가 가지고있는 기존의 페이스 북 SDK를 함께 검사 해달라고에서 확인할 수 있습니다. 같은 문제에 직면 해있다. – Swati

+3

예, 긴급합니다. iOS 앱에서하고 있습니다. 이 기능이 포함 된 AppStore에 제출해야합니다. – Swati

답변

관련 문제