If you get this error message after updating your Facebook library files:
Fatal error: Call to undefined method FacebookRestClient::users_isAppAdded()
Try changing this code:
<?php /* ... */ try { if (!$facebook->api_client->users_isAppAdded()) { $facebook->redirect($facebook->get_add_url()); } } catch (Exception $ex) { //this will clear cookies for your application and redirect them to a login prompt $facebook->set_user(null, null); $facebook->redirect($appcallbackurl); } /* ... */ ?>
With this:
<?php /* ... */ try { if (!$facebook->api_client->users_isAppUser()) { $facebook->redirect($facebook->get_add_url()); } } catch (Exception $ex) { //this will clear cookies for your application and redirect them to a login prompt $facebook->set_user(null, null); $facebook->redirect($appcallbackurl); } /* ... */ ?>
Use this at your own risk, it seems to fix the problem and I’m hoping it won’t introduce bugs in other places…
Hamid Alipour is a partner in Codehead, LLP with his wife, Tess. Hamid speaks 12 markup and programming languages [Yes, 12: PHP, CSS, Ajax, JavaScript, HTML/XHTML, Java, Python, C/C++, ASP, Visual Basic, Scheme and Action Script]; has a penchant for solving the unsolvable; an affinity for clean, hand-written code and is a Zend Certified 
Works like a charm!!
Comment
if you were around, i wud like to kiss you….coz it works for me after hours of digging…
Comment