Yoast\WP\SEO\Presenters\Open_Graph
Type_Presenter{}
Presenter class for the Open Graph type.
Хуки из класса
Использование
$Type_Presenter = new Type_Presenter(); // use class methods
Методы
- public get()
Код Type_Presenter{} Type Presenter{} Yoast 24.1
class Type_Presenter extends Abstract_Indexable_Tag_Presenter { /** * The tag key name. * * @var string */ protected $key = 'og:type'; /** * The tag format including placeholders. * * @var string */ protected $tag_format = self::META_PROPERTY_CONTENT; /** * Run the opengraph type content through the `wpseo_opengraph_type` filter. * * @return string The filtered type. */ public function get() { /** * Filter: 'wpseo_opengraph_type' - Allow changing the opengraph type. * * @param string $type The type. * @param Indexable_Presentation $presentation The presentation of an indexable. */ return (string) \apply_filters( 'wpseo_opengraph_type', $this->presentation->open_graph_type, $this->presentation ); } }