0 สมาชิก และ 1 บุคคลทั่วไป กำลังดูหัวข้อนี้
{ global $txt, $modSettings, $boardurl; if (!empty ($modSettings['oasl_api_key']) && !empty ($modSettings['oasl_enabled_providers'])) { // Extract the chosen providers. $providers = explode (',', trim ($modSettings['oasl_enabled_providers'])); // Create Random integer to prevent id collision. $rand = mt_rand (99999, 9999999); // Separe from the traditional login. echo '<hr />'; // Display error messages if there are any. if ( isset ($_REQUEST['oasl_err'])) { switch ($_REQUEST['oasl_err']) { case 'user_does_not_exist': echo '<p class="error">'.$txt['oasl_user_does_not_exist'].'</p>'; break; case 'user_require_activation': echo '<p class="error">'.$txt['oasl_user_require_activation'].'</p>'; break; case 'user_registration_disabled': echo '<p class="error">'.$txt['oasl_user_may_not_register'].'</p>'; break; } } if ( ! empty ($modSettings['oasl_settings_login_caption'])) { echo ' <p style="text-align:left;"> <strong>', $modSettings['oasl_settings_login_caption'], '</strong> </p>'; } echo ' <p style="text-align:left;"> <div class="oneall_social_login_providers" id="oneall_social_login_providers_', $rand, '"></div> <script type="text/javascript"> oneall.api.plugins.social_login.build("oneall_social_login_providers_', $rand, '", { "providers": [\'', implode ("', '", $providers), '\'], "callback_uri": \'', $boardurl, '/index.php?action=oasl_callback;oasl_source=login\', }); </script> <!-- OneAll.com / Social Login for SMF --> </p>'; }}
.oneall_social_login_providers {margin: 0 auto;width: 152px;}
/* Styles for Social Login Buttons */.plugin #providers .provider { width: 50px !important; margin-bottom: 2px !important; padding: 2px 4px 4px;} .plugin #providers .provider .name { display: none !important;} .plugin #providers .provider .button { background: url("http://appliancejunk.com/images/social/facebook_24x24.gif") no-repeat scroll 0 0 transparent !important; height: 24px !important; width: 24px !important;}
<div id="social_login_container"></div><script type="text/javascript"> oneall.api.plugins.social_login.build("social_login_container", { "providers" : ["facebook", "twitter", "google", "yahoo", "openid", "windowslive"], "callback_uri": "http://appliancejunk.com/forums/index.php?action=oasl_callback;oasl_source=register", "css_theme_uri": "http://appliancejunk.com/forums/social_login.css" });</script>';