Answer the question
In order to leave comments, you need to log in
Bitrix how to add an attachment to a letter template to the standard form of Bitrix?
There is a form in which there are 3 fields: name, email, attached file
The code that sends the form according to the template:
$SITE_ID = 's1';
$EVENT_TYPE = 'form_job_vacancy';
$arMailFields = array(
'NAME' => $_POST["form_user_name"],
'EMAIL' => $_POST["form_user_email"],
'NAME_JOB' => $_POST["form_user_name_job"],
'CURL_FILE_PATH' => $_COOKIE['curl'],
);
$arMailFields_clear=array();
foreach ($arMailFields as $key => $value)
{
$input_text = strip_tags($value);
$input_text = htmlspecialchars($input_text);
//$input_text = mysql_escape_string($input_text);
$arMailFields_clear[$key]=$input_text;
}
CEvent::Send("FORM_FILLING_FORM_JOB_VACANCY", $SITE_ID, $arMailFields_clear, "N");
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question