4
嗨,我想通過Facebook登錄使用Facebook圖形API。我使用下面的代碼顯示登錄如何使用facebook-opengraph插件登錄yii
<?php $this->widget('ext.yii-facebook-opengraph.plugins.LoginButton', array(
'show_faces'=>true,
'registration_url'=>'http://mysite/index.php/users/facebookregister',
'oauth'=>true, // JS SDK -enable OAuth 2.0
)); ?>
,並在重定向的頁面我在做什麼
<?php $userinfo = Yii::app()->facebook->getInfo() // gets the Graph info of the current user ?>
but it gives me error
Property "LoginButton.oauth" is not defined.
i am follwing this url to http://www.yiiframework.com/extension/facebook-opengraph/
請確保您已按照擴展頁面上的說明進行配置並正確配置。確保配置中的組件數組中的oauth設置爲true。 – Orlymee