This topic has 4 replies, 2 voices, and was last updated 7 years, 2 months ago ago by Rose Tyler
Hi, some months ago I asked you a help to customize the buttons on the portfolio page. You replied that it was out of your service and I had to ask an external developer. I did so and hired him.
In this months he was able to do almost all things I asked him.
For example, he was able to put the number with the count on all buttons.
The number between brackets after the name of the category is correct.
The problem is the number between brackets in the first button (“Show All”). In this case, the count is not exact because it collects all posts in every language. I would like the count is only for the language showed in that moment. The developer told me that the problem is the javascript used in theme and, according to him, only who wrote it can solve this problem. He worked several days wihtout find a solution.
He used this code (
<?php
$count_posts = wp_count_posts('etheme_portfolio');
$total_posts = $count_posts->publish;
echo $total_posts . ')';
?>
to do the task, but as said it is not perfect. Do you have any idea on how to correct it?
Please see below in the pvt content the link to see the result.
Hello,
Please note that we recommend to make changes in a child theme to prevent of losing modifications after theme update. Otherwise you need to save changed file and reupload it after update.
Change this code http://prntscr.com/gqnvwd to
$i = 0;
while ( $loop->have_posts() ) : $loop->the_post(); $i++; endwhile;
echo $i . ')';
in framework/portfolio.php file.
Regards
Hi Rose, thank you very much!!!
Finally, I was able to solve this point after months of attempts.
Your client service is really very expert.
You’re welcome!
Regards
The issue related to '‘Buttons count’' has been successfully resolved, and the topic is now closed for further responses