Delete
bool CBlogCategory::Delete( int ID );
The method deletes a category with the ID. Non-static method.
Method parameters
Parameter | Description |
---|---|
ID | Category ID. |
Returned value
The method returns true if the category was deleted successfully, otherwise returns false.Examples of use
<? if(!CBlogCategory::Delete($ID)) { echo 'Category deletion error'.$ID; } else echo 'Category is deleted удалена.'; ?>
Deleting all block tags:
CModule::IncludeModule ("blog"); $dbCategory = CBlogCategory::GetList (Array ("ID" => "ASC"), Array ("BLOG_ID" => 5)); while ($arCategory = $dbCategory->Fetch()) { CBlogCategory::Delete ($arCategory["ID"]); }
© «Bitrix24», 2001-2024