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 7923407
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T17:18:56+00:00 2026-06-03T17:18:56+00:00

i get an error while trying to automatically post a link with Facebook Graph

  • 0

i get an error while trying to automatically post a link with Facebook Graph API

My php code

<?
  $config = array();
  $config['appId'] = '3545XXXXXXX6207';
  $config['secret'] = '60068XXXXXXXXXXXe45a426';

  $facebook = new Facebook($config);

$retour_login = json_decode(stripslashes($_GET['session']), true);
$uid = $retour_login['uid'];
$access_token = $retour_login['access_token'];

$me = null;

if ($session) {
  try {
    $uid = $facebook->getUser();
    $me = $facebook->api('/me');
  } catch (FacebookApiException $e) {
    error_log($e);
  }
}

if(!isset($_GET['session'])) { // Asking permissions
    $params = array(
    'locale' => 'fr_FR',
    'display' => 'popup', 
    'req_perms' => 'email,user_about_me,user_birthday,user_location',
    'ext_perms' => 'publish_stream,share_item,manage_pages'
    );
    header("Location: ".$facebook->getLoginUrl($params));
}



        $args = array(
                'message'   => "XXXX",
                'link'      => 'XXXX',
                'name'      => 'XXXX',
                'picture'   => 'XXXX',
                "caption"=> "lien.com",
                      "type"=> "link");

        $post_id = $facebook->api("/me/links", "post", $args); // execute this to automatically post on FB

?>

I get this error : OAuthException: (#282) Requires extended permission: share_item thrown

Any ideas ?

Thanks!

  • 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-03T17:19:00+00:00Added an answer on June 3, 2026 at 5:19 pm

    What are ‘req_perms’ and ‘ext_perms’ there? the permissions should be in a ‘scope’ parameter according to the documentation – https://developers.facebook.com/docs/reference/dialogs/oauth/ and https://developers.facebook.com/docs/authentication/

    Check you’re not working from an outdated example or tutorial – always check the official documentation first

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I got this error while trying to get facebook access_token from node.js server: {error:{message:(#803)
While trying to validate my forms i get the following error: Expected a {
While trying to insert data to my SQl db i get the following error
While trying to validate form data on my page i get the following error:
I get this error, while I'm testing the code below: You have an error
I get this error while trying to access documentum through webtop. An error has
{Configuration system failed to initialize} i get this error while trying to run a
get a complier error while trying to do float_val=float_val<<1; It gives out a error
I get an error like 'htmlfile: Unknown runtime error' while trying to show fusion
I get this error while trying to dump database, i entered linuxuser $ sudo

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.