is_redirect

Definition:
function is_redirect ($sc) {}

Parameters

  • $sc

Source code

function is_redirect ($sc) {

	return $sc >= 300 && $sc < 400;

}

2169

is_preview

Definition:
function is_preview() {}

Is the query for a post or page preview?

Source code

	function is_preview() {

		return (bool) $this->is_preview;

	}

2167

is_post_type_hierarchical

Definition:
function is_post_type_hierarchical( $post_type ) {}

Whether the post type is hierarchical.
A false return value might also mean that the post type does not exist.

Parameters

  • string $post_type: Post type name

Return values

returns:Whether post type is hierarchical.

Source code

function is_post_type_hierarchical( $post_type ) {

	if ( ! post_type_exists( $post_type ) )

		return false;



	$post_type = get_post_type_object( $post_type );

	return $post_type->hierarchical;

}

2165

is_plugin_page

Definition:
function is_plugin_page() {}

Whether the current page was created by a plugin.
The plugin can set this by using the global $plugin_page and setting it to true.

Source code

function is_plugin_page() {

	global $plugin_page;



	if ( isset($plugin_page) )

		return true;



	return false;

}

2163

is_plugin_active_for_network

Definition:
function is_plugin_active_for_network( $plugin ) {}

Check whether the plugin is active for the entire network.

Parameters

  • string $plugin: Base plugin path from plugins directory.

Return values

returns:True, if active for the network, otherwise false.

Source code

function is_plugin_active_for_network( $plugin ) {

	if ( !is_multisite() )

		return false;



	$plugins = get_site_option( 'active_sitewide_plugins');

	if ( isset($plugins[$plugin]) )

		return true;



	return false;

}

2161