Google Analytics Dashboard for WP in Custom Column
-
12-05-2021 - |
Question
So I've customised my custom post type columns so they display in the order I would like.
add_filter('manage_publications_posts_columns', 'set_publication_custom_columns');
function set_publication_custom_columns( $columns ) {
$columns = array(
'cb' => '<input type="checkbox" />',
'title' => __('Title'),
'pub_category' => __('Categories'),
'pub_tag' => __('Tags'),
'thumb' => __('Cover'),
'date' => __('Date'),
'analytics' => __( 'Analytics' )
);
return $columns;
}
But I'm using the Google Analytics Dashboard for WP plugin which adds an 'Analytics' column and stats icon at the end. Except now I've customised my columns I don't know how to call the GADWP to appear or use in my
add_action('manage_publications_posts_custom_column', 'custom_publications_columns', 10, 2 );
function custom_publications_columns( $column, $post_id ) {
...
}
?
https://wordpress.org/plugins/google-analytics-dashboard-for-wp
La solution
I found it. Searched in the google-analytics-dashboard-for-wp
plugin folder for posts_custom_column
and found reference to gadwp_stats:
'gadwp_stats' => __( 'Analytics' )
Licencié sous: CC-BY-SA avec attribution
Non affilié à wordpress.stackexchange