Automattic\WooCommerce\Internal\Admin
Marketplace::maybe_open_woo_tab()
Open the Woo tab when the user clicks on the Woo link in the plugin installer.
Method of the class: Marketplace{}
No Hooks.
Return
null
. Nothing (null).
Usage
$Marketplace = new Marketplace(); $Marketplace->maybe_open_woo_tab();
Marketplace::maybe_open_woo_tab() Marketplace::maybe open woo tab code WC 9.5.1
public function maybe_open_woo_tab() { // phpcs:disable WordPress.Security.NonceVerification.Recommended if ( ! isset( $_GET['tab'] ) || self::MARKETPLACE_TAB_SLUG !== $_GET['tab'] ) { return; } // phpcs:enable WordPress.Security.NonceVerification.Recommended $woo_url = add_query_arg( array( 'page' => 'wc-admin', 'path' => '/extensions', 'tab' => 'extensions', 'ref' => 'plugins', ), admin_url( 'admin.php' ) ); wp_safe_redirect( $woo_url ); exit; }