Please see this gist:
https://gist.github.com/ajaydsouza/9b1bc56cec79295e784c
You can try adding this code to your theme’s functions.php
Hi,
Thanks for your answer.
We tried and added the code to functions.php but it didn’t work. There is still no difference between the Dutch and English side. On both sides it counts the Dutch read blogs.
Hope you can help.
Thanks,
Linda
What’s your site URL?
Could you please clarify what you mean by counts Dutch read blogs? The code snippet above is only for displaying the posts not counting.
Hi,
My website is http://www.thebluebutterfly.nl.
With the language selector you can switch to the English side.
On both sides of my website, in the sidebar, you will see the popular post widget.
As you will see on both sides the Dutch most read blogs appear.
I hoped to see the most read English blogs on the English side of my website.
Thanks for helping me out.
Linda
Can you check if you have the cache enabled in the settings page. And if so, could you please disable this?
It was enabled. I have disabled it now.
Should I also press ‘clear cache’?
Hi,
I have disabled the cache and pressed ‘clear cache’.
At the moment it is working better than it used to be. Thank you for this help.
Unfortunately it isn’t what I expected to happen.
I know that on my website, there is a difference in popular posts. There are different posts popular on the Dutch side then there are on the English side.
I hoped this would show as well in the plugin.
Now it seems that the plugin chooses the best read Dutch posts, then only translates the title of the post into English. Because on both sides (Dutch and English) it shows the same posts. According to the statistics it isn’t right, there are other posts popular on the English side.
Is there a way to make sure it counts both popular posts?
Thanks for your help.
That is indeed a strange behaviour. I must confess I will need to do much more testing on this. My tests on a sample install (I don’t have a multi-ligual site) didn’t reveal anything weird since it did pull the right set of posts.
Is the default language of your site Dutch?
My default language is Dutch.
Thanks for your help.
I don’t have a solution right now. Any chance of having a staging site created where I can test the plugin and change settings etc.
If so, could you please contact me via https://webberzone.com/contact with the details?