Created
March 16, 2016 11:06
-
-
Save d1i1m1o1n/f8b983c35e948a597daa to your computer and use it in GitHub Desktop.
Для компонента sale.order.ajax если вдруг понадобится авторизация через социальные сети
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div style="display:none;"> | |
<?$APPLICATION->IncludeComponent( | |
"bitrix:system.auth.form", | |
"", | |
Array( | |
"COMPONENT_TEMPLATE" => ".default", | |
"FORGOT_PASSWORD_URL" => "", | |
"PROFILE_URL" => "", | |
"REGISTER_URL" => "", | |
"SHOW_ERRORS" => "N" | |
) | |
);?> | |
</div> | |
<style> | |
.socserv_form .bx-auth { | |
width: auto; | |
margin: 30px 0 0 0; | |
} | |
</style> | |
<div style="/*display:none;*/" class="socserv_form"> | |
<? | |
$arParamsToDelete = array( | |
"login", | |
"login_form", | |
"logout", | |
"register", | |
"forgot_password", | |
"change_password", | |
"confirm_registration", | |
"confirm_code", | |
"confirm_user_id", | |
"logout_butt", | |
); | |
CModule::IncludeModule("socialservices"); | |
$oAuthManager = new CSocServAuthManager(); | |
$arServices = $oAuthManager->GetActiveAuthServices(array( | |
'BACKURL' => $APPLICATION->GetCurPageParam("", $arParamsToDelete), | |
'FOR_INTRANET' => false, | |
)); | |
?> | |
<?//echo "<pre style='display:block;'>"; print_r($arResult); echo "</pre>";?> | |
<? | |
$APPLICATION->IncludeComponent("bitrix:socserv.auth.form", "", | |
array( | |
"AUTH_SERVICES" => $arServices, | |
"CURRENT_SERVICE" => false, | |
"AUTH_URL" => $APPLICATION->GetCurPageParam("login=yes", $arParamsToDelete), | |
"POST" => $arResult["POST"], | |
"SHOW_TITLES" => 'Y', | |
"FOR_SPLIT" => 'N', | |
"AUTH_LINE" => 'Y', | |
), | |
$component, | |
array("HIDE_ICONS"=>"Y") | |
); | |
?> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment