WordPress at Your Fingertips
function is not described

WC_Admin_Setup_Wizard::get_next_step_link() public WC 3.0.0

Deprecated from version 4.6.0. It is no longer supported and can be removed in future releases. It is recommended to replace this function with the same one.

Get the URL for the next step's screen.

{} It's a method of the class: WC_Admin_Setup_Wizard{}

No Hooks.

Return

String. URL for next step if a next step exists. Admin URL if it's the last step. Empty string on failure.

Usage

$WC_Admin_Setup_Wizard = new WC_Admin_Setup_Wizard();
$WC_Admin_Setup_Wizard->get_next_step_link( $step );
$step(string)
slug (default: current step).
Default: ''

Changelog

Since 3.0.0 Introduced.
Deprecated 4.6.0

Code of WC_Admin_Setup_Wizard::get_next_step_link() WC 5.9.0

public function get_next_step_link( $step = '' ) {
	_deprecated_function( __CLASS__ . '::' . __FUNCTION__, '4.6.0', 'Onboarding is maintained in WooCommerce Admin.' );
	if ( ! $step ) {
		$step = $this->step;
	}

	$keys = array_keys( $this->steps );
	if ( end( $keys ) === $step ) {
		return admin_url();
	}

	$step_index = array_search( $step, $keys, true );
	if ( false === $step_index ) {
		return '';
	}

	return add_query_arg( 'step', $keys[ $step_index + 1 ], remove_query_arg( 'activate_error' ) );
}