Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8189995
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T03:28:13+00:00 2026-06-07T03:28:13+00:00

I’m trying to make a Facebook video application so users can have a video

  • 0

I’m trying to make a Facebook video application so users can have a video stored on my site displayed on their wall using Facebook Open Graph.

I’m using the below code for user login.

<script>
    window.fbAsyncInit = function() {
        FB.init({
            appId      : 'MYAPPID', // App ID
            status     : true, // check login status
            cookie     : true, // enable cookies to allow the server to access the session
            xfbml      : true  // parse XFBML
        });
    };

    // Load the SDK asynchronously
    (function(d){
        var js, id = 'facebook-jssdk'; if (d.getElementById(id)) {return;}
        js = d.createElement('script'); js.id = id; js.async = true;
        js.src = "//connect.facebook.net/en_US/all.js";
        d.getElementsByTagName('head')[0].appendChild(js);
    }(document));
</script>

Now how do I implement the Watch action?

curl -F 'access_token=myaccesstoken' \
 -F 'movie=http://samples.ogp.me/453907197960619' \
    'https://graph.facebook.com/me/video.watches'

And this

curl 'https://graph.facebook.com/me/video.watches?access_token=myaccesstoken'

in PHP? And how can I get the access token of users?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T03:28:16+00:00Added an answer on June 7, 2026 at 3:28 am

    To get the user access token in PHP SDK 3.1.1:

    // Get the current access token
    $access_token = $facebook->getAccessToken();
    

    Refer to: https://developers.facebook.com/docs/reference/php/facebook-getAccessToken/


    Posting Actions.

    Refer to: https://developers.facebook.com/docs/opengraph/tutorial/

    This tutorial will guide you through the key steps to build, test, and publish your first Open Graph application. We will build a sample recipe application that allows users to publish stories about cooking recipes. Before starting, please review the Open Graph Checklist which will not only help in your app design and planning, but will also help speed up the application review process.

    Step 1: Create a Facebook applications. https://developers.facebook.com/docs/opengraph/tutorial/#create-app

    Step 2: Authenticate users with the Login Button plugin. https://developers.facebook.com/docs/opengraph/tutorial/#authenticate

    Step 3: Define Objects, Actions and Aggregations through the App Dashboard. https://developers.facebook.com/docs/opengraph/tutorial/#define

    Step 4: Publish Actions for your users. https://developers.facebook.com/docs/opengraph/tutorial/#publish

    Step 5: Add Social Plugins to your application. https://developers.facebook.com/docs/opengraph/tutorial/#plugins

    Step 6: Submit Your Actions for approval. https://developers.facebook.com/docs/opengraph/tutorial/#submit

    EXAMPLE:

    if ($user){
        $queries = array(
            // The URL build is me/ namespace : action ? object = URL
            array('method' => 'POST', 'relative_url' => '/me/anotherfeed:view?feed=http://anotherfeed.com/')
            // Any other API calls needed, this is a batch request for performance.
        );
    
        try {
            $postResponseA = $facebook->api('?batch='.json_encode($queries), 'POST');
        }
        catch (FacebookApiException $e) {
            //echo 'AF error: '.$e.'';
        }
        // Returns the id of posted actions if true.
        $actions = json_decode($postResponseA[0][body], true);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm new to using the Perl treebuilder module for HTML parsing and can't figure
I have a string like this: La Torre Eiffel paragonata all&#8217;Everest What PHP function
I have a French site that I want to parse, but am running into
I have thousands of HTML files to process using Groovy/Java and I need to
I am trying to loop through a bunch of documents I have to put
I have a bunch of posts stored in text files formatted in yaml/textile (from
I have a .ini file as follows: [playlist] numberofentries=2 File1=http://87.230.82.17:80 Title1=(#1 - 365/1400) Example
I am trying to understand how to use SyndicationItem to display feed which is
Basically, what I'm trying to create is a page of div tags, each has
link Im having trouble converting the html entites into html characters, (&# 8217;) i

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.