This commit is contained in:
root
2025-11-13 19:52:28 +03:00
parent 8aeeb05b7d
commit 807dec3b6c
4646 changed files with 163445 additions and 626017 deletions

View File

@@ -786,30 +786,34 @@ class CPosting
foreach ($arFiles as $arFile)
{
if ($post_arr['CHARSET'] <> '')
{
$from_charset = $post_arr['MSG_CHARSET'] ?: SITE_CHARSET;
$file_name = Encoding::convertEncoding($arFile['ORIGINAL_NAME'], $from_charset, $post_arr['CHARSET']);
}
else
{
$file_name = $arFile['ORIGINAL_NAME'];
}
$sBody .=
$eol . '--' . $sBoundary . $eol
. 'Content-Type: ' . $arFile['CONTENT_TYPE'] . '; name="' . $file_name . '"' . $eol
. 'Content-Transfer-Encoding: base64' . $eol
. 'Content-Disposition: attachment; filename="' . CMailTools::EncodeHeaderFrom($file_name, $post_arr['CHARSET']) . '"' . $eol . $eol;
$arTempFile = CFile::MakeFileArray($arFile['ID']);
$sBody .= chunk_split(
base64_encode(
file_get_contents($arTempFile['tmp_name'])
),
72,
$eol
);
if (is_array($arTempFile) && $arTempFile['tmp_name'])
{
if ($post_arr['CHARSET'] <> '')
{
$from_charset = $post_arr['MSG_CHARSET'] ?: SITE_CHARSET;
$file_name = Encoding::convertEncoding($arFile['ORIGINAL_NAME'], $from_charset, $post_arr['CHARSET']);
}
else
{
$file_name = $arFile['ORIGINAL_NAME'];
}
$sBody .= $eol
. '--' . $sBoundary . $eol
. 'Content-Type: ' . $arFile['CONTENT_TYPE'] . '; name="' . $file_name . '"' . $eol
. 'Content-Transfer-Encoding: base64' . $eol
. 'Content-Disposition: attachment; filename="' . CMailTools::EncodeHeaderFrom($file_name, $post_arr['CHARSET']) . '"' . $eol
. $eol
. chunk_split(
base64_encode(
file_get_contents($arTempFile['tmp_name'])
),
72,
$eol
)
;
}
}
}

View File

@@ -775,7 +775,7 @@ class CSubscription
SELECT ID
FROM b_subscription
WHERE CONFIRMED <> 'Y'
AND DATE_CONFIRM < " . $helper->addDaysToDateTime(1) . "
AND DATE_CONFIRM < " . $helper->addDaysToDateTime(-$interval) . "
";
$res = $connection->query($sql);
$sIn = '0';