• Модуль: socialnetwork
  • Путь к файлу: ~/bitrix/modules/socialnetwork/lib/component/loglist/param.php
  • Класс: BitrixSocialnetworkComponentLogListParam
  • Вызов: Param::prepareCommentFormParams
public function prepareCommentFormParams(&$componentParams): void
{
	$requestParams = $this->getRequest()->getPost('params');

	$componentParams['UID'] = (
		!empty($requestParams)
		&& is_array($requestParams)
		&& !empty($requestParams['commentFormUID'])
			? $requestParams['commentFormUID']
			: BitrixMainSecurityRandom::getString(4)
	);

	$componentParams['BLOG_UID'] = (
		!empty($requestParams)
		&& is_array($requestParams)
		&& !empty($requestParams['blogCommentFormUID'])
			? $requestParams['blogCommentFormUID']
			: BitrixMainSecurityRandom::getString(4)
	);

	$componentParams['FORM_ID'] = 'sonetCommentForm' . $componentParams['UID'];
	$componentParams['BLOG_FORM_ID'] = 'blogCommentForm' . $componentParams['BLOG_UID'];
}