Note that there are some explanatory texts on larger screens.

plurals
  1. POWhat is wrong with Facebook and Twitter APIs?
    text
    copied!<p>Is anyone else noticing that facebook and twitters APIs aren't working?</p> <p>For facebook even if I allow my application to have access to my wall</p> <pre><code>$facebook-&gt;getUser() </code></pre> <p>Is always 0... When I try to open <strong>getLoginUrl</strong> it just open pop-up and redirect it instantly to success return link...</p> <p>Here is code:</p> <pre><code>require_once 'src/base_facebook.php'; require_once 'src/facebook.php'; $app_id = 'xxx'; $app_secret = 'xxx'; $facebook = new Facebook(array( 'appId' =&gt; $app_id, 'secret' =&gt; $app_secret, 'oauth' =&gt; true, 'cookie' =&gt; true )); $req_perms = "publish_stream"; $user = $facebook-&gt;getUser(); if (!$user) { $loginUrl = $facebook-&gt;getLoginUrl(array('display' =&gt; 'popup', 'redirect_uri' =&gt; 'http://xxxx.com/return_close.php?success=1', 'cancel_url' =&gt; 'http://xxxx.com/return_close.php?success=0','req_perms' =&gt; $req_perms, 'scope' =&gt; $req_perms)); } </code></pre> <p>And for twitter it's like someone mistyped return link... When I open <strong>getAuthorizeURL</strong> and when I log in it redirects me to this URL:</p> <pre><code>https://twitter.comoauth_callback/?oauth_token=yA2xjLsVRm9tIuVEysXnCV8R7TISW8tF94uznn7zlw&amp;oauth_verifier=Io1N2I8zOEzJeBWI77WXFMqmMRNDfCrXZGQxXmxJLbI </code></pre> <p>Yes, <strong>https://twitter.comoauth_callback/</strong> is right, there is no / after .com, it's together, so I get not found page...</p> <p>It's like both APIs have serious problems... Facebook sometimes work and sometimes doesn't, it's buggy a lot...</p> <p>Facebook library downloaded from OFFICIAL GitHub page. Tried versions:</p> <pre><code>v3.1.1 v3.1.0 v3.0.1 </code></pre> <p>And none of those work...</p> <hr> <p>Update</p> <p>Return URL ( redirect_uri ) <strong>MUST</strong> have facebook class included in file...</p> <p>There is so many examples/documentations and none of those had this explained...</p> <p>So, Facebook fixed... Twitter still not working...</p> <hr>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload