Recent

Stopwords_Command class Pro only

Stopwords_Command

Stopwords management commands for Better Search.

Namespace: WebberZone\Better_Search\Pro\CLI
Since: 4.3.0
Source: includes/cli/class-stopwords-command.php line 21 Extends: Base_Command

Methods

add()

Add stopwords to the plugin settings.

OPTIONS

… : One or more stopwords to add, separated by spaces.

[—network] : Add stopwords for all sites in the network.

[—blog-id=] : Specific blog ID to add stopwords for (multisite only).

EXAMPLES

wp bsearch stopwords add the and a an
wp bsearch stopwords add --network "the" "and" "a"

Line: 45

public function add( array $args, array $assoc_args ): void;
TypeNameDescription
array$argsCommand arguments.
array$assoc_argsCommand associative arguments.

Returns: void

remove()

Remove stopwords from the plugin settings.

OPTIONS

… : One or more stopwords to remove, separated by spaces.

[—network] : Remove stopwords for all sites in the network.

[—blog-id=] : Specific blog ID to remove stopwords for (multisite only).

EXAMPLES

wp bsearch stopwords remove the and a an
wp bsearch stopwords remove --network "the" "and"

Line: 118

public function remove( array $args, array $assoc_args ): void;
TypeNameDescription
array$argsCommand arguments.
array$assoc_argsCommand associative arguments.

Returns: void

list()

List all stopwords.

OPTIONS

[—format=] : Output format (table, json, csv). Default: table.

[—network] : List stopwords for all sites in the network.

[—blog-id=] : Specific blog ID to list stopwords for (multisite only).

EXAMPLES

wp bsearch stopwords list
wp bsearch stopwords list --format=json
wp bsearch stopwords list --network

Line: 193

public function list( array $args, array $assoc_args ): void;
TypeNameDescription
array$argsCommand arguments.
array$assoc_argsCommand associative arguments.

Returns: void

clear()

Clear all stopwords.

OPTIONS

[—force] : Skip confirmation prompt.

[—network] : Clear stopwords for all sites in the network.

[—blog-id=] : Specific blog ID to clear stopwords for (multisite only).

EXAMPLES

wp bsearch stopwords clear
wp bsearch stopwords clear --force
wp bsearch stopwords clear --network

Line: 258

public function clear( array $args, array $assoc_args ): void;
TypeNameDescription
array$argsCommand arguments.
array$assoc_argsCommand associative arguments.

Returns: void