You appear to be a bot. Output may be restricted
Description
Indexes all your content to ensure the best performance.
OPTIONS
[–network] : Performs the indexation on all sites within the network. [–reindex] : Removes all existing indexables and then reindexes them. [–skip-confirmation] : Skips the confirmations (for automated systems). [–interval=<interval>] : The number of microseconds (millionths of a second) to wait between index actions. — default: 500000 —
EXAMPLES
- wp yoast index
Usage
$void = Index_Command::index( $args, $assoc_args );
Parameters
- $args
- ( array|null ) optional – The arguments.
- $assoc_args
- ( array|null ) optional – The associative arguments.
Returns
void
Source
File name: wordpress-seo/src/commands/index-command.php
Lines:
1 to 22 of 22
public function index( $args = null, $assoc_args = null ) { if ( ! isset( $assoc_args['network'] ) ) { $this->run_indexation_actions( $assoc_args ); return; } $criteria = [ 'fields' => 'ids', 'spam' => 0, 'deleted' => 0, 'archived' => 0, ]; $blog_ids = \get_sites( $criteria ); foreach ( $blog_ids as $blog_id ) { \switch_to_blog( $blog_id ); \do_action( '_yoast_run_migrations' ); $this->run_indexation_actions( $assoc_args ); \restore_current_blog(); } }