Tagged: comment count, comment number
- This topic has 6 replies, 2 voices, and was last updated 4 years, 7 months ago by Theme Horse Support Team.
-
AuthorPosts
-
September 13, 2019 at 10:45 pm #67933September 22, 2019 at 12:58 pm #68273Theme Horse Support TeamKeymaster
Hi Alberto,
Apologies for the late reply. We missed your topic.
Anyways for this it needs code customization and you need to hire a developer as this is a new feature to add in the theme.Thank you!
September 22, 2019 at 1:06 pm #68274AlbertoParticipantOkay, tell me the files to edit that I do it
September 27, 2019 at 7:56 am #68453Theme Horse Support TeamKeymasterHi Alberto,
You have to customize the
wp_portfolio_theloop_for_archive()
function code which is in file inc > structure > content-extentions.php on line no: 133
Make sure you have created a child theme for customization so that your customization won’t lost after update.Thank you!
September 27, 2019 at 11:29 am #68479AlbertoParticipantI put this code in the file you told me, line 147, you can see here https://albertifoto.altervista.org
I would have liked to add the link to the comments, but I failed.
I tried the code in the child functions.php but it doesn’t work.<div class="commenti-anteprime"> <?php if (1 == get_comments_number()) { printf(__('One thought on “%2$s”', 'wp-portfolio') , number_format_i18n(get_comments_number()) , '<span>' . get_the_title() . '</span>'); } else { printf(__('%1$s thoughts on “%2$s”', 'wp-portfolio') , number_format_i18n(get_comments_number()) , '<span>' . get_the_title() . '</span>'); } ?> </div>
October 1, 2019 at 2:04 pm #68631AlbertoParticipantSOLVED!
Now there is also the link:
<?php if (1 == get_comments_number()) { printf(__('<a href="' . get_permalink() . '#comments"> 1 commento</a>', 'wp-portfolio') , number_format_i18n(get_comments_number())); } else { printf(__('<a href="' . get_permalink() . '#comments"> %1$s commenti</a>', 'wp-portfolio') , number_format_i18n(get_comments_number())); } ?>
October 2, 2019 at 7:20 am #68674Theme Horse Support TeamKeymasterHi Alberto,
Great that you solved it.
If you have any problem do not hesitate to contact us.Thank you!
-
AuthorPosts
- You must be logged in to reply to this topic.