Answer the question
In order to leave comments, you need to log in
How to update a detailed picture in the Bitrix infoblock?
Good evening.
There was a problem when trying to overwrite the detailed image of an infoblock element. When you create a new element, everything works, but when you edit it, it does not change. I tried to add 'del' = "Y" and 'old_file' = "" to the end of the array, but all in vain..
$arLoadProductArray = Array(
"MODIFIED_BY" => $USER->GetID(),
"IBLOCK_SECTION" => false,
"NAME" => $_REQUEST["40"],
"DETAIL_PICTURE" => CFile::MakeFileArray(1583),
);
Answer the question
In order to leave comments, you need to log in
CFile::MakeFileArray($pathToFile) does not take a number, but the path to the file. For example something like this:
CFile::MakeFileArray($_SERVER["DOCUMENT_ROOT"]."/image.gif");
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question