function OnAfterUserRegisterHandler(&$arFields)
{
$toSend = Array();
$toSend["PASSWORD"] = $arFields["CONFIRM_PASSWORD"];
$toSend["EMAIL"] = $arFields["EMAIL"];
$toSend["USER_ID"] = $arFields["ID"];
$toSend["USER_IP"] = $arFields["USER_IP"];
$toSend["USER_HOST"] = $arFields["USER_HOST"];
$toSend["LOGIN"] = $arFields["LOGIN"];
$toSend["NAME"] = (trim ($arFields["NAME"]) == "")? $toSend["NAME"] = htmlspecialchars('Не указано'): $arFields["NAME"];
$toSend["LAST_NAME"] = (trim ($arFields["LAST_NAME"]) == "")? $toSend["LAST_NAME"] = htmlspecialchars('Не указано'): $arFields["LAST_NAME"];
$toSend["UF_ORG_NAME"] = (trim ($arFields["UF_ORG_NAME"]) == "")? $toSend["UF_ORG_NAME"] = htmlspecialchars('Не указано'): $arFields["UF_ORG_NAME"];
$toSend["UF_UR_ADDRESS"] = (trim ($arFields["UF_UR_ADDRESS"]) == "")? $toSend["UF_UR_ADDRESS"] = htmlspecialchars('Не указано'): $arFields["UF_UR_ADDRESS"];
$toSend["UF_INN"] = (trim ($arFields["UF_INN"]) == "")? $toSend["UF_INN"] = htmlspecialchars('Не указано'): $arFields["UF_INN"];
$toSend["UF_KPP"] = (trim ($arFields["UF_KPP"]) == "")? $toSend["UF_KPP"] = htmlspecialchars('Не указано'): $arFields["UF_KPP"];
CEvent::SendImmediate ("NEW_USER_FULL", SITE_ID, $toSend);
return $arFields;
} |