本文整理汇总了PHP中thebuggenie\core\framework\Settings::isPersonaAvailable方法的典型用法代码示例。如果您正苦于以下问题:PHP Settings::isPersonaAvailable方法的具体用法?PHP Settings::isPersonaAvailable怎么用?PHP Settings::isPersonaAvailable使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类thebuggenie\core\framework\Settings
的用法示例。
在下文中一共展示了Settings::isPersonaAvailable方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: rgba
?>
">
</div>
</form>
<?php
if (\thebuggenie\core\framework\Settings::isPersonaAvailable() || \thebuggenie\core\framework\Settings::isOpenIDavailable()) {
?>
<div style="text-align: center;">
<fieldset style="border: 0; border-top: 1px dotted rgba(0, 0, 0, 0.3); padding: 10px 100px; width: 100px; margin: 15px auto 0 auto;">
<legend style="text-align: center; width: 100%; background-color: transparent;"><?php
echo __('%regular_login or %persona_or_openid_login', array('%regular_login' => '', '%persona_or_openid_login' => ''));
?>
</legend>
</fieldset>
<?php
if (\thebuggenie\core\framework\Settings::isPersonaAvailable()) {
?>
<a class="persona-button" id="persona-signin-button" href="#"><span><?php
echo __('Sign in with Persona');
?>
</span></a>
<?php
}
?>
<?php
if (\thebuggenie\core\framework\Settings::isOpenIDavailable()) {
?>
<a class="persona-button orange" id="openid-signin-button" href="javascript:void(0);" onclick="$('regular_login_container').toggleClassName('active');$('openid_container').toggleClassName('active');"><span><?php
echo __('Sign in with OpenID');
?>
</span></a>
示例2: include_component
</div>
<div id="fullpage_backdrop_content" class="fullpage_backdrop_content"> </div>
</div>
<?php
if (\thebuggenie\core\framework\Context::getRouting()->getCurrentRouteName() != 'login_page' && $tbg_user->isGuest()) {
?>
<div id="login_backdrop" class="fullpage_backdrop" style="display: none;">
<div id="login_content" class="fullpage_backdrop_content">
<?php
include_component('main/loginpopup', array('content' => get_component_html('main/login'), 'mandatory' => false));
?>
</div>
</div>
<?php
}
if (\thebuggenie\core\framework\Settings::isPersonaAvailable() && ($tbg_user->isGuest() || $tbg_request->hasCookie('tbg3_persona_session'))) {
?>
<script src="https://login.persona.org/include.js"></script>
<script type="text/javascript">
require(['domReady', 'thebuggenie/tbg', 'jquery'], function (domReady, tbgjs, jquery) {
domReady(function () {
TBG = tbgjs;
var currentUser = <?php
echo !$tbg_user->isGuest() ? "'{$tbg_user->getEmail()}'" : 'null';
?>
;
navigator.id.watch({
loggedInUser: currentUser,
onlogin: function(assertion) {
// A user has logged in! Here you need to: