A
A
Alexey Grebenikov2014-03-20 10:05:26
1C-Bitrix
Alexey Grebenikov, 2014-03-20 10:05:26

Is it possible to delete an infoblock along with images (Bitrix)?

Good afternoon! When importing the unloading, new infoblocks were created (duplicated). Images were also imported into them.
Question: if you delete an infoblock of the Catalog type, will all the images that are present in it be deleted?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vadim Yakovlev, 2014-03-20
@grealexti

In CIBlockElement::Delete

$db_res = CIBlockElement::GetProperty($zr["IBLOCK_ID"], $zr["ID"], "sort", "asc", array("PROPERTY_TYPE"=>"F"));
......
while($res = $db_res->Fetch())
CIBlockElement::DeleteFile($res["VALUE"], $zr["ID"], "PROPERTY", $zr["WF_PARENT_ELEMENT_ID"], $zr["IBLOCK_ID"]);

Answer: yes.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question