Bitrix Site Manager

CAdvBanner::ResetKeywords

array
CAdvBanner::ResetKeywords(
 varchar(255) TYPE_SID="",
 varchar(255) LOGIC="",
 char(1) EXACT_MATCH=""
);

The method deletes keywords assigned to a page. Depending on parameters passed, the method can delete all keywords or those only defined by parameters.

Parameters

ParameterDescription
TYPE_SID Symbolic identifier of the advertisement type. If specified, the method deletes keywords assigned to this type only.
LOGIC Specifies which keywords of the banner to delete. Possible values:
EXACT_MATCH Specifies the type of keywords to delete with respect to their match exactness settings.

If set to "Y", the method deletes only those keywords which are required to fully match the sample.

If set to "N", the method deletes keywords which are required to be at least a part of the sample.

Example

Consider the following keywords array:

Array
(
    [LEFT] => Array
    (
        [REQUIRED] => Array
        (
            [Y] => Array
            (
                [0] => GeForce
                [1] => Radeon
            )
            [N] => Array
            (
                [0] => video
                [1] => directx
            )
        )

        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => game
                [1] => 3D
            )
        )
    )

    [] => Array
    (
        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => GeForce
                [1] => Radeon
                [2] => Sony
            )
        )
    )

    [TOP] => Array
    (
        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => BMW
                [1] => top soft
                [2] => XP
            )
        )
    )
)

The below is the modified array after a call to CAdvBanner::ResetKeywords("LEFT","REQUIRED","N"):

Array
(
    [LEFT] => Array
    (
        [REQUIRED] => Array
        (
            [Y] => Array
            (
                [0] => GeForce
                [1] => Radion
            )
        )

        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => game
                [1] => 3D
            )
        )
    )

    [] => Array
    (
        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => GeForce
                [1] => Radion
                [2] => Sony
            )
        )
    )

    [TOP] => Array
    (
        [DESIRED] => Array
        (
            [N] => Array
            (
                [0] => BMW
                [1] => top soft
                [2] => Print
            )
        )
    )
)