当前位置: 首页>>代码示例>>PHP>>正文


PHP CSocNetLog::InitUsersTmp方法代码示例

本文整理汇总了PHP中CSocNetLog::InitUsersTmp方法的典型用法代码示例。如果您正苦于以下问题:PHP CSocNetLog::InitUsersTmp方法的具体用法?PHP CSocNetLog::InitUsersTmp怎么用?PHP CSocNetLog::InitUsersTmp使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CSocNetLog的用法示例。


在下文中一共展示了CSocNetLog::InitUsersTmp方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: list

             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_ACTIVITY_TITLE_GROUP1"), GetMessage("SONET_ACTIVITY_TITLE_GROUP1"), $arParams);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "ungroup":
             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_ACTIVITY_TITLE_UNGROUP1"), GetMessage("SONET_ACTIVITY_TITLE_UNGROUP1"), $arParams);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "exclude_user":
             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_ACTIVITY_TITLE_EXCLUDE_USER1"), GetMessage("SONET_ACTIVITY_TITLE_EXCLUDE_USER1"), $arParams);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "exclude_group":
             list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvents["MESSAGE"], GetMessage("SONET_ACTIVITY_TITLE_EXCLUDE_GROUP1"), GetMessage("SONET_ACTIVITY_TITLE_EXCLUDE_GROUP1"), $arParams);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         default:
             continue;
             break;
     }
 }
 $arTmpUser = array("NAME" => "", "LAST_NAME" => "", "SECOND_NAME" => "", "LOGIN" => "");
 if ($arEvents["ENTITY_TYPE"] == SONET_ENTITY_USER && intval($arEvents["ENTITY_ID"]) > 0) {
     $arTmpUser = array("NAME" => $arEvents["~USER_NAME"], "LAST_NAME" => $arEvents["~USER_LAST_NAME"], "SECOND_NAME" => $arEvents["~USER_SECOND_NAME"], "LOGIN" => $arEvents["~USER_LOGIN"]);
 }
 $arTmpEvent = array("ID" => $arEvents["ID"], "ENTITY_TYPE" => $arEvents["ENTITY_TYPE"], "ENTITY_ID" => $arEvents["ENTITY_ID"], "EVENT_ID" => $arEvents["EVENT_ID"], "LOG_DATE" => $arEvents["LOG_DATE"], "LOG_TIME_FORMAT" => $timeFormated, "TITLE_TEMPLATE" => $arEvents["TITLE_TEMPLATE"], "TITLE" => $arEvents["TITLE"], "TITLE_FORMAT" => CSocNetLog::MakeTitle($arEvents["TITLE_TEMPLATE"], $arEvents["TITLE"], $arEvents["URL"], true), "MESSAGE" => $arEvents["MESSAGE"], "MESSAGE_FORMAT" => $arEvents["MESSAGE_FORMAT"], "URL" => $arEvents["URL"], "MODULE_ID" => $arEvents["MODULE_ID"], "CALLBACK_FUNC" => $arEvents["CALLBACK_FUNC"], "ENTITY_NAME" => $arEvents["ENTITY_TYPE"] == SONET_ENTITY_GROUP ? $arEvents["GROUP_NAME"] : CUser::FormatName($arParams['NAME_TEMPLATE'], $arTmpUser, $bUseLogin), "ENTITY_PATH" => $path2Entity);
 if ($arEvents["ENTITY_TYPE"] == SONET_ENTITY_USER) {
     $arTmpEvent["USER_NAME"] = $arTmpUser["NAME"];
开发者ID:Satariall,项目名称:izurit,代码行数:31,代码来源:component.php

示例2: OnSocNetLogFormatEvent

	public static function OnSocNetLogFormatEvent($arEvent, $arParams)
	{
		if ($arEvent["EVENT_ID"] == "system" || $arEvent["EVENT_ID"] == "system_friends" || $arEvent["EVENT_ID"] == "system_groups")
		{
			$arEvent["TITLE_TEMPLATE"] = "";
			$arEvent["URL"] = "";

			switch ($arEvent["TITLE"])
			{
				case "join":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_JOIN1"), GetMessage("SONET_GL_TITLE_JOIN2"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "unjoin":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_UNJOIN1"), GetMessage("SONET_GL_TITLE_UNJOIN2"), $arParams);
					$arEvents["TITLE"] = $titleTmp;
					$arEvents["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "moderate":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_MODERATE1"), GetMessage("SONET_GL_TITLE_MODERATE2"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "unmoderate":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_UNMODERATE1"), GetMessage("SONET_GL_TITLE_UNMODERATE2"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "owner":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_OWNER1"), GetMessage("SONET_GL_TITLE_OWNER1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "friend":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_FRIEND1"), GetMessage("SONET_GL_TITLE_FRIEND1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "unfriend":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_UNFRIEND1"), GetMessage("SONET_GL_TITLE_UNFRIEND1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "group":
					list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_GROUP1"), GetMessage("SONET_GL_TITLE_GROUP1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "ungroup":
					list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_UNGROUP1"), GetMessage("SONET_GL_TITLE_UNGROUP1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "exclude_user":
					list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_EXCLUDE_USER1"), GetMessage("SONET_GL_TITLE_EXCLUDE_USER1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				case "exclude_group":
					list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvent["MESSAGE"], GetMessage("SONET_GL_TITLE_EXCLUDE_GROUP1"), GetMessage("SONET_GL_TITLE_EXCLUDE_GROUP1"), $arParams);
					$arEvent["TITLE"] = $titleTmp;
					$arEvent["MESSAGE_FORMAT"] = $messageTmp;
					break;
				default:
					continue;
					break;
			}
		}
		return $arEvent;
	}
开发者ID:ASDAFF,项目名称:bxApiDocs,代码行数:71,代码来源:log.php

示例3: list

             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_C73_TITLE_GROUP1"), GetMessage("SONET_C73_TITLE_GROUP1"), $arParams, true);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "ungroup":
             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_C73_TITLE_UNGROUP1"), GetMessage("SONET_C73_TITLE_UNGROUP1"), $arParams, true);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "exclude_user":
             list($titleTmp, $messageTmp) = CSocNetLog::InitGroupsTmp($arEvents["MESSAGE"], GetMessage("SONET_C73_TITLE_EXCLUDE_USER1"), GetMessage("SONET_C73_TITLE_EXCLUDE_USER1"), $arParams, true);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         case "exclude_group":
             list($titleTmp, $messageTmp) = CSocNetLog::InitUsersTmp($arEvents["MESSAGE"], GetMessage("SONET_C73_TITLE_EXCLUDE_GROUP1"), GetMessage("SONET_C73_TITLE_EXCLUDE_GROUP1"), $arParams, $bCurrentUserIsAdmin, true);
             $arEvents["TITLE"] = $titleTmp;
             $arEvents["MESSAGE_FORMAT"] = $messageTmp;
             break;
         default:
             continue;
             break;
     }
 }
 $protocol = CMain::IsHTTPS() ? "https://" : "http://";
 $arEvents["MESSAGE_FORMAT"] = preg_replace("#(<a\\s[^>/]*?href\\s*=\\s*)(['\"])(.+?)(\\2)#i", "\\1\\2" . $protocol . $arResult["SERVER_NAME"] . "\\3\\4", $arEvents["MESSAGE_FORMAT"]);
 $arEvents["MESSAGE_FORMAT"] = preg_replace("#(<img\\s[^>/]*?src\\s*=\\s*)(['\"])(.+?)(\\2)#i", "\\1\\2" . $protocol . $arResult["SERVER_NAME"] . "\\3\\4", $arEvents["MESSAGE_FORMAT"]);
 $arTmpUser = array("NAME" => $arEvents["~USER_NAME"], "LAST_NAME" => $arEvents["~USER_LAST_NAME"], "SECOND_NAME" => $arEvents["~USER_SECOND_NAME"], "LOGIN" => $arEvents["~USER_LOGIN"]);
 $arEvents["LOG_DATE"] = date("r", MkDateTime($GLOBALS["DB"]->FormatDate($arEvents["LOG_DATE"], CLang::GetDateFormat("FULL"), "DD.MM.YYYY H:I:S"), "d.m.Y H:i:s"));
 $arEvents["URL"] = __RSSCheckServerName($arEvents["URL"], $arResult["SERVER_NAME"]);
 $arTmpEvent = array("ID" => $arEvents["ID"], "LOG_DATE" => $arEvents["LOG_DATE"], "TITLE_FORMAT" => CSocNetLog::MakeTitle($arEvents["TITLE_TEMPLATE"], $arEvents["TITLE"], "", true), "MESSAGE_FORMAT" => htmlspecialcharsbx($arEvents["MESSAGE_FORMAT"]), "URL" => htmlspecialcharsbx($arEvents["URL"]));
开发者ID:webgksupport,项目名称:alpina,代码行数:31,代码来源:component.php


注:本文中的CSocNetLog::InitUsersTmp方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。