Documentation

delete

 public static
\Bitrix\Main\Config\Option::delete(
 string $moduleId,
 array $filter = array()
);

This static method deletes values of module parameters from database for the site. The value is only one, array of fields cannot be passed. It means that multiple parameters cannot be simultaneously deleted only by listing their names.

Similar to the method COption::RemoveOption in the old core.

Parameters

ParameterDescriptionVersion
$moduleIdModule ID. Required.
$nameParameter namebefore 14.0.0
$siteIdSite identifierbefore 14.0.0
$filterArray of filter keys
  • name - parameter name
  • site_id - site ID (can be empty)
from 14.0.0

Excpetions

Examples

Option::delete("main", array(
    "name" => "max_file_size",
    "site_id" => "s2"
    )
);


© «Bitrix24», 2001-2022
Up