PHP 클래스 The_SEO_Framework\Detect

Detects other plugins and themes
부터: 2.7.1
상속: extends Render
파일 보기 프로젝트 열기: sybrew/the-seo-framework

공개 메소드들

메소드 설명
active_plugins ( ) : array Returns list of active plugins.
can_do_sitemap_robots ( ) : boolean Determines whether to add a line within robots based by plugin detection, or sitemap output option.
can_get_term_meta ( ) : boolean Determines whether we can use the new WordPress core term meta functionality.
can_i_use ( array $plugins = [], boolean $use_cache = true ) Detect if you can use the given constants, functions and classes.
can_manipulate_title ( ) : boolean Checks whether we can use special manipulation filters.
check_wp_locale ( string $locale = '', boolean $use_cache = true ) : boolean Detect WordPress language.
conflicting_plugins ( ) : array Filterable list of conflicting plugins.
current_theme_supports_title_tag ( ) : boolean Checks a theme's support for title-tag.
detect_og_plugin ( ) : boolean Determines if other Open Graph or SEO plugins are active.
detect_plugin ( array $plugins ) : boolean Detect active plugin by constant, class or function existence.
detect_plugin_multi ( array $plugins ) : boolean Detect active plugin by constant, class or function existence.
detect_seo_plugins ( ) : boolean Determines if other SEO plugins are active.
detect_sitemap_plugin ( ) : boolean Determines if other Sitemap plugins are active.
detect_theme_support ( $features, boolean $use_cache = true ) : boolean Checks for current theme support.
detect_twitter_card_plugin ( ) : boolean Determines if other Twitter Card plugins are active.
get_conflicting_plugins ( string $type = 'seo_tools' ) : array Fetches type of conflicting plugins.
get_supported_post_type ( boolean $public = true, string $post_type = '' ) : boolean | string Checks (current) Post Type for if this plugin may use it.
has_json_ld_plugin ( ) : boolean Determines if other Schema.org LD+Json plugins are active.
has_page_on_front ( ) : boolean Determines whether a page or blog is on front.
has_robots_txt ( ) : boolean Detects presence of robots.txt in root folder.
has_sitemap_xml ( ) : boolean Detects presence of sitemap.xml in root folder.
is_domainmapping_active ( ) : boolean Detects WPMUdev Domain Mapping plugin.
is_donncha_domainmapping_active ( ) : boolean Detects Donncha Domain Mapping plugin.
is_post_type_page ( string $type ) : boolean Detect if the current screen type is a page or taxonomy.
is_qtranslate_active ( ) : boolean Detect qTranslate X plugin.
is_theme ( string | array $themes = '' ) : boolean Checks if the (parent) theme name is loaded.
is_wpml_active ( ) : boolean Detects WPML plugin.
post_type_supports_custom_seo ( string $post_type = '' ) : boolean Check if post type supports The SEO Framework.
post_type_supports_inpost ( string | null $post_type = null ) : boolean Determines if the post type is compatible with The SEO Framework inpost metabox.
set_tell_title_doing_it_wrong ( null | string $title = null, null | string $sep = null, null | string $seplocation = null ) : void Sets up doing it wrong html code for in the footer.
tell_title_doing_it_wrong ( null | string $title = null, null | string $sep = null, null | string $seplocation = null, boolean $output = true ) : void Adds doing it wrong html code in the footer.
theme_title_doing_it_right ( ) : boolean Determines whether the theme is outputting the title correctly based on transient.
theme_title_fix_active ( ) : boolean Detect theme title fix extension plugin.
wp_version ( string $version = '4.3.0', string $compare = '>=' ) : boolean Determines if WP is above or below a version

보호된 메소드들

메소드 설명
__construct ( ) Constructor, load parent constructor

메소드 상세

__construct() 보호된 메소드

Constructor, load parent constructor
protected __construct ( )

active_plugins() 공개 메소드

Returns list of active plugins.
부터: 2.6.1
public active_plugins ( ) : array
리턴 array List of active plugins.

can_do_sitemap_robots() 공개 메소드

Determines whether to add a line within robots based by plugin detection, or sitemap output option.
부터: 2.6.0
public can_do_sitemap_robots ( ) : boolean
리턴 boolean True when no conflicting plugins are detected or when The SEO Framework's Sitemaps are output.

can_get_term_meta() 공개 메소드

Determines whether we can use the new WordPress core term meta functionality.
부터: 2.7.0
public can_get_term_meta ( ) : boolean
리턴 boolean True when WordPress is at version 4.4 or higher and has an accordingly upgraded database.

can_i_use() 공개 메소드

All must be available to return true.
부터: 2.5.2
public can_i_use ( array $plugins = [], boolean $use_cache = true )
$plugins array Array of array for constants, classes and / or functions to check for plugin existence.
$use_cache boolean Bypasses cache if false

can_manipulate_title() 공개 메소드

Checks whether we can use special manipulation filters.
부터: 2.6.0
public can_manipulate_title ( ) : boolean
리턴 boolean True if we can manipulate title.

check_wp_locale() 공개 메소드

Considers en_UK, en_US, en, etc.
부터: 2.6.0
public check_wp_locale ( string $locale = '', boolean $use_cache = true ) : boolean
$locale string Required, the locale.
$use_cache boolean Set to false to bypass the cache.
리턴 boolean Whether the locale is in the WordPress locale.

conflicting_plugins() 공개 메소드

Applies filters 'the_seo_framework_conflicting_plugins' : array
부터: 2.6.0
public conflicting_plugins ( ) : array
리턴 array List of conflicting plugins.

current_theme_supports_title_tag() 공개 메소드

Checks a theme's support for title-tag.
부터: 2.6.0

detect_og_plugin() 공개 메소드

Determines if other Open Graph or SEO plugins are active.
부터: 1.3.0 Applies filters 'the_seo_framework_og_plugin_detected' : bool
부터: 2.6.1
public detect_og_plugin ( ) : boolean
리턴 boolean True if OG or SEO plugin detected.

detect_plugin() 공개 메소드

Detect active plugin by constant, class or function existence.
부터: 1.3.0
public detect_plugin ( array $plugins ) : boolean
$plugins array Array of array for constants, classes and / or functions to check for plugin existence.
리턴 boolean True if plugin exists or false if plugin constant, class or function not detected.

detect_plugin_multi() 공개 메소드

All parameters must match and return true.
부터: 2.5.2
public detect_plugin_multi ( array $plugins ) : boolean
$plugins array Array of array for constants, classes and / or functions to check for plugin existence.
리턴 boolean True if ALL functions classes and constants exists or false if plugin constant, class or function not detected.

detect_seo_plugins() 공개 메소드

Determines if other SEO plugins are active.
부터: 1.3.0 Applies filters 'the_seo_framework_seo_plugin_detected' : bool
부터: 2.6.1
public detect_seo_plugins ( ) : boolean
리턴 boolean SEO plugin detected.

detect_sitemap_plugin() 공개 메소드

Determines if other Sitemap plugins are active.
부터: 2.1.0
public detect_sitemap_plugin ( ) : boolean
리턴 boolean

detect_theme_support() 공개 메소드

Maintains detection cache, array and strings are mixed through foreach loops.
부터: 2.2.5
public detect_theme_support ( $features, boolean $use_cache = true ) : boolean
$use_cache boolean If set to false don't use cache.
리턴 boolean theme support.

detect_twitter_card_plugin() 공개 메소드

Determines if other Twitter Card plugins are active.
부터: 2.6.0
public detect_twitter_card_plugin ( ) : boolean
리턴 boolean Twitter Card plugin detected.

get_conflicting_plugins() 공개 메소드

Fetches type of conflicting plugins.
부터: 2.6.0
public get_conflicting_plugins ( string $type = 'seo_tools' ) : array
$type string The Key from $this->conflicting_plugins()
리턴 array

get_supported_post_type() 공개 메소드

Checks (current) Post Type for if this plugin may use it.
부터: 2.6.0
public get_supported_post_type ( boolean $public = true, string $post_type = '' ) : boolean | string
$public boolean Whether to only get Public Post types.
$post_type string Optional. The post type to check.
리턴 boolean | string The Allowed Post Type.

has_json_ld_plugin() 공개 메소드

Determines if other Schema.org LD+Json plugins are active.
부터: 1.3.0
부터: 2.6.1 Always return false. Let other plugin authors decide its value.
public has_json_ld_plugin ( ) : boolean
리턴 boolean Whether another Schema.org plugin is active.

has_page_on_front() 공개 메소드

Determines whether a page or blog is on front.
부터: 2.6.0
public has_page_on_front ( ) : boolean
리턴 boolean

has_robots_txt() 공개 메소드

Detects presence of robots.txt in root folder.
부터: 2.5.2
public has_robots_txt ( ) : boolean
리턴 boolean Whether the robots.txt file exists.

has_sitemap_xml() 공개 메소드

Detects presence of sitemap.xml in root folder.
부터: 2.5.2
public has_sitemap_xml ( ) : boolean
리턴 boolean Whether the sitemap.xml file exists.

is_domainmapping_active() 공개 메소드

Detects WPMUdev Domain Mapping plugin.
부터: 2.3.0

is_donncha_domainmapping_active() 공개 메소드

Detects Donncha Domain Mapping plugin.
부터: 2.4.0

is_post_type_page() 공개 메소드

Detect if the current screen type is a page or taxonomy.
부터: 2.3.1
public is_post_type_page ( string $type ) : boolean
$type string the Screen type
리턴 boolean true if post type is a page or post

is_qtranslate_active() 공개 메소드

Detect qTranslate X plugin.
부터: 2.6.0
public is_qtranslate_active ( ) : boolean
리턴 boolean

is_theme() 공개 메소드

Checks if the (parent) theme name is loaded.
부터: 2.1.0
public is_theme ( string | array $themes = '' ) : boolean
$themes string | array the current theme name.
리턴 boolean is theme active.

is_wpml_active() 공개 메소드

Detects WPML plugin.
부터: 2.6.0
public is_wpml_active ( ) : boolean
리턴 boolean

post_type_supports_custom_seo() 공개 메소드

Doesn't work on admin_init.
부터: 2.3.9
public post_type_supports_custom_seo ( string $post_type = '' ) : boolean
$post_type string The current post type.
리턴 boolean true of post type is supported.

post_type_supports_inpost() 공개 메소드

Determines if the post type is compatible with The SEO Framework inpost metabox.
부터: 2.3.5
public post_type_supports_inpost ( string | null $post_type = null ) : boolean
$post_type string | null
리턴 boolean True if post type is supported.

set_tell_title_doing_it_wrong() 공개 메소드

Sets up doing it wrong html code for in the footer.
부터: 2.7.0
public set_tell_title_doing_it_wrong ( null | string $title = null, null | string $sep = null, null | string $seplocation = null ) : void
$title null | string The given title
$sep null | string The separator
$seplocation null | string Whether the blogname is left or right.
리턴 void

tell_title_doing_it_wrong() 공개 메소드

Adds doing it wrong html code in the footer.
부터: 2.5.2.1
public tell_title_doing_it_wrong ( null | string $title = null, null | string $sep = null, null | string $seplocation = null, boolean $output = true ) : void
$title null | string The given title
$sep null | string The separator
$seplocation null | string Whether the blogname is left or right.
$output boolean Whether to store cache values or echo the output in the footer.
리턴 void

theme_title_doing_it_right() 공개 메소드

Determines whether the theme is outputting the title correctly based on transient.
부터: 2.5.2
public theme_title_doing_it_right ( ) : boolean
리턴 boolean True theme is doing it right.

theme_title_fix_active() 공개 메소드

Detect theme title fix extension plugin.
부터: 2.6.0
public theme_title_fix_active ( ) : boolean
리턴 boolean True theme will do it right.

wp_version() 공개 메소드

Determines if WP is above or below a version
부터: 2.2.1
부터: 2.3.8
public wp_version ( string $version = '4.3.0', string $compare = '>=' ) : boolean
$version string the three part version to compare to WordPress
$compare string the comparing operator, default "$version >= Current WP Version"
리턴 boolean True if the WordPress version comparison passes. Note: When using $compare = '>' it will be false when they are equal.