示例#1
0
			{
				$detail_url = $arElement['DETAIL_PAGE_URL'];
				$element_name = $arElement['NAME'];
				$element_code = $arElement['CODE'];
				$detail_url = str_replace('%2F', '/', $detail_url);
			}

			$rsSites = CSite::GetByID(SITE_ID);
			if ($arSite = $rsSites->Fetch())
			{
				$siteName = $arSite["NAME"];
			}

			$arEmailFieldsActivated = array(
				"COMMENT_ID" => intval($_POST['ACTIVATE_ON']),
				"USER_ID" => intval($AxObject->GetUserID($_POST['ACTIVATE_ON'])),
				"ELEMENT_ID" => $element_id,
				"ELEMENT_CODE" => $element_code,
				"ELEMENT_NAME" => trim($element_name),
				"DETAIL_PAGE_URL" => trim($detail_url),
				"USER_LOGIN" => trim($AxObject->GetUserLogin($_POST['ACTIVATE_ON'])),
				"EMAIL_FROM" => $mail_sender,
				"EMAIL_TO" => $to_Mail_activated,
				"SITE_NAME" => $siteName
			);

			CEvent::Send("PRMEDIA_TC_ACTIVATE", SITE_ID, $arEmailFieldsActivated, false);
		}
	}
}
示例#2
0
文件: component.php 项目: ASDAFF/mp
						}

						$rsSites = CSite::GetByID(SITE_ID);
						if ($arSite = $rsSites->Fetch())
							$siteName = $arSite["NAME"];
					}

					/**
					 * SEND TO USER AFTER ANSWERING
					 * */
					if ($arResult['SEND_TO_USER_AFTER_ANSWERING'] == "Y" && $arResult['PREMODERATION'] != 'Y' && $to_Mail_answer != 'N' && !($user_name == $comment->IsYours($NEW_ID, 'answer')))
					{
						$arEmailFieldsAnswering = array(
							"COMMENT_ID" => $NEW_ID,
							"COMMENT_TEXT" => $arPreparedFields['COMMENT'],
							"USER_ID" => intval($comment->GetUserID($NEW_ID)),
							"ELEMENT_ID" => $arParams["OBJECT_ID"],
							"ELEMENT_CODE" => $element_code,
							"ELEMENT_NAME" => $element_name,
							"DETAIL_PAGE_URL" => $detail_url,
							"USER_LOGIN" => $user_name,
							"PARENT_ID" => intval($arPreparedFields['PARENT_ID']),
							"EMAIL_FROM" => $mail_sender,
							"EMAIL_TO" => $to_Mail_answer,
							"SITE_NAME" => $siteName
						);

						CEvent::Send("PRMEDIA_TC_USER", SITE_ID, $arEmailFieldsAnswering, false);
					}

					/**