Forum Replies Created
-
AuthorPosts
-
nici-
MemberI resolved it by editing the [post_comment] output format directly in the widget options to [post_comments zero="0" one="1" more="%"] and styling everything via css.
nici-
MemberOk, I found out I can define
zero="0" one="1" more="%"
right in the widget settings! Great!
nici-
MemberSecond problem: When editing the output of featured post widget here
genesis > lib > widgets > featured-post-widget.php
than these changes will be overwritten by updating genesis, right?
I'd like to add some more content to the output like star rating etc. I guess there must be a hook to add things _into the content output_ of the widget?
Best regards
nici-nici-
MemberHi there,
I tried editing the post_info part in featured post widget. I want to change the output format of the post_comments to something like:
[post_comments zero="0" one="1" more="%"]
Thus I added this format details into the featured post widget on line 54:
'post_info' => '[post_date] ' . __( 'By', 'genesis' ) . ' [post_author_posts_link] [post_comments zero="0" one="1" more="%"]',
Only unfortunately the widget still outputs the default format including the word "Comments" etc.
Any hint on how I can change the output format of post_comment in featured post widget?
Best regards and thank you,
nici-
nici-
MemberSorry, I forgot the code.
I modified the featured image in blog page and single post this way:
// Display featured image on top of single post and add comment count
add_action( 'genesis_before_entry', 'featured_post_image', 8 );
function featured_post_image() {
// if ( !is_singular( 'post' ) ) return;
print "<div class=\"featured-image\">";
the_post_thumbnail('post-image');
print "<div class=\"comment-icon\"><span class=\"dashicons dashicons-format-chat\"></span> ";
print comments_number( '0', '1', '%');
print "</div></div>";
}[yes I might clean this up a bit, I am it's still testing around]
And now I'd like to have the [blog_info] output in featured post widget on the start page similar with only the comment numbers as above (and icon, but I can add this via CSS so nevermind).
January 15, 2018 at 3:00 pm in reply to: Exclude Blog Page when Adding an Action / Remove Action from Blog Page (NewsPro) #215430nici-
MemberGreat, thanks a lot!
-
AuthorPosts