WP_Customize_Manager::wp_redirect_status( int $status ): int

This method has been deprecated.

Prevents Ajax requests from following redirects when previewing a theme by issuing a 200 response instead of a 30x.

Description

Instead, the JS will sniff out the location header.

Parameters

$statusintrequired
Status.

Return

int

Source

public function wp_redirect_status( $status ) {
	_deprecated_function( __FUNCTION__, '4.7.0' );

	if ( $this->is_preview() && ! is_admin() ) {
		return 200;
	}

	return $status;
}

Changelog

VersionDescription
4.7.0This method has been deprecated.
3.4.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.