Yoast\WP\SEO\AI_Generator\User_Interface

Ai_Generator_Integration::get_connect_urlprivateYoast 1.0

Builds the nonce-protected Integrations-page URL that auto-starts the MyYoast connection flow when opened.

The nonce keeps the auto-start trigger from being cross-site forgeable; the Integrations page verifies it before kicking off the flow.

Built with add_query_arg() wp_create_nonce() than wp_nonce_url(): the latter HTML-encodes the & separators for markup output, but this URL is localized and assigned to a React href, where it isn't decoded — the browser would then send amp;start-myyoast-connection as the query-arg name and the flow would never start. This form keeps the separators as plain &.

Метод класса: Ai_Generator_Integration{}

Хуков нет.

Возвращает

Строку. The connect URL.

Использование

// private - только в коде основоного (родительского) класса
$result = $this->get_connect_url();

Код Ai_Generator_Integration::get_connect_url() Yoast 28.3

private function get_connect_url() {
	return \add_query_arg(
		'_wpnonce',
		\wp_create_nonce( 'wpseo-start-myyoast-connection' ),
		\self_admin_url( 'admin.php?page=' . Integrations_Page::PAGE . '&start-myyoast-connection=1' ),
	);
}