本文整理汇总了PHP中iaUsers::getProvidersTable方法的典型用法代码示例。如果您正苦于以下问题:PHP iaUsers::getProvidersTable方法的具体用法?PHP iaUsers::getProvidersTable怎么用?PHP iaUsers::getProvidersTable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类iaUsers
的用法示例。
在下文中一共展示了iaUsers::getProvidersTable方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Exception
if (!$memberId) {
if ($memberInfo = $this->iaDb->row_bind(iaDb::ALL_COLUMNS_SELECTION, "`email` = :email_address", array('email_address' => $user_profile->email), iaUsers::getTable())) {
$iaCore->iaDb->insert(array('member_id' => $memberInfo['id'], 'name' => $providerName, 'value' => $user_profile->identifier), null, iaUsers::getProvidersTable());
$memberId = $memberInfo['id'];
}
}
// register new member if no matches
if (!$memberId) {
$memberRegInfo['username'] = '';
$memberRegInfo['email'] = $user_profile->email;
$memberRegInfo['fullname'] = $user_profile->displayName;
// $memberRegInfo['avatar'] = $user_profile->photoURL;
$memberRegInfo['disable_fields'] = true;
$memberId = $iaUsers->register($memberRegInfo);
// add providers match
$iaCore->iaDb->insert(array('member_id' => $memberId, 'name' => $providerName, 'value' => $user_profile->identifier), null, iaUsers::getProvidersTable());
// no need to validate address
$iaUsers->update(array('id' => $memberId, 'sec_key' => '', 'status' => iaCore::STATUS_ACTIVE));
}
// authorize
$iaUsers->getAuth($memberId);
} else {
throw new Exception("User is not logged in.");
}
} catch (Exception $e) {
$iaCore->iaView->setMessages("HybridAuth error: " . $e->getMessage(), iaView::ERROR);
}
}
if (iaUsers::hasIdentity()) {
$iaPage = $iaCore->factory('page', iaCore::FRONT);
$iaCore->factory('util')->go_to($iaPage->getUrlByName('profile'));