title: Facebook Graph Api: Share a link with a specified locale?
body: <p>I am trying to automatically share a link with the graph api, but
  by specifing a locale so the shared link only appears to for example English users.</p>
  
  <p>Here is the PHP code using Facebook php sdk.</p>
  
  <pre><code>try {
      $res = $facebook-&gt;api('/' . $PAGEID . '/feed/', 'POST',
      array(
          'access_token' =&gt; $pageToken,
          'link' =&gt; $url,
          'scrape' =&gt; 'true',
          'locale' =&gt; 'en_US'
      ));
  } catch(FacebookApiException $e) {
  }
  </code></pre>
  
  <p>Here are the meta data in the head of the url i am sharing</p>
  
  <pre><code>&lt;meta property="og:description" content="" /&gt;
  &lt;meta property="og:image" content="http://www.example.com/image.jpg" /&gt;
  &lt;meta property="og:locale" content="en_US" /&gt;
  &lt;meta property="og:site_name" content="Example.com" /&gt;
  &lt;meta property="og:title" content="Example.com" /&gt;
  &lt;meta property="og:url" content="http://www.example.com/" /&gt;
  </code></pre>
  
  <p>I tried to change en_US by en_us.
  I also selected a primary language French in the "App Dashboard Localization" and a second language English.</p>
  
  <p>Sharing a link works, but for everyone, the locale is not working... :(</p>
  
  <p>EDIT Resolved : Example for all English locales
  The id of locales can be found by querying <a href="https://graph.facebook.com/search?q=en&amp;type=adlocale" rel="nofollow">https://graph.facebook.com/search?q=en&amp;type=adlocale</a></p>
  
  <pre><code>try {
      $res = $facebook-&gt;api('/' . $PAGEID . '/feed/', 'POST',
      array(
          'access_token' =&gt; $pageToken,
          'link' =&gt; $url,
          'targeting' =&gt; "{'locales':['6', '51', '24', '1001']}"
      ));
  } catch(FacebookApiException $e) {
  }
  </code></pre>