Yoast\WP\SEO\Integrations\Admin
Link_Count_Columns_Integration::add_post_columns() public Yoast 1.0
Adds the columns for the post overview.
{} Это метод класса: Link_Count_Columns_Integration{}
Хуков нет.
Возвращает
Массив. The extended array with columns.
Использование
$Link_Count_Columns_Integration = new Link_Count_Columns_Integration(); $Link_Count_Columns_Integration->add_post_columns( $columns );
- $columns(массив) (обязательный)
- Array with columns.
Код Link_Count_Columns_Integration::add_post_columns() Link Count Columns Integration::add post columns Yoast 15.6.2
public function add_post_columns( $columns ) {
if ( ! \is_array( $columns ) ) {
return $columns;
}
$columns[ 'wpseo-' . self::COLUMN_LINKS ] = \sprintf(
'<span class="yoast-linked-to yoast-column-header-has-tooltip" data-tooltip-text="%1$s"><span class="screen-reader-text">%2$s</span></span>',
\esc_attr__( 'Number of outgoing internal links in this post. See "Yoast Columns" text in the help tab for more info.', 'wordpress-seo' ),
\esc_html__( 'Outgoing internal links', 'wordpress-seo' )
);
if ( $this->post_link_indexing_action->get_total_unindexed() === 0 ) {
$columns[ 'wpseo-' . self::COLUMN_LINKED ] = \sprintf(
'<span class="yoast-linked-from yoast-column-header-has-tooltip" data-tooltip-text="%1$s"><span class="screen-reader-text">%2$s</span></span>',
\esc_attr__( 'Number of internal links linking to this post. See "Yoast Columns" text in the help tab for more info.', 'wordpress-seo' ),
\esc_html__( 'Received internal links', 'wordpress-seo' )
);
}
return $columns;
}