145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

Hello,

Do you know a way to get a numeration/ranking (1., 2., 3.,...) for the products in the shop list. So there should always be a number before the title – on the shop page and the category shop page.

My default sorting is “sort by average rating”, so it would make sense that there is a ranking.

Thank you

279 posts
  • Sold between 50 000 and 100 000 dollars
  • Exclusive Author
  • Has been a member for 1-2 years
  • Bought between 10 and 49 items
  • Referred between 10 and 49 users
PrimaThemes says

average rating is based on customer review. are you sure to use it as renumeration/ranking here?

145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

yes, there should be a number 1 product, number 2, etc.

279 posts
  • Sold between 50 000 and 100 000 dollars
  • Exclusive Author
  • Has been a member for 1-2 years
  • Bought between 10 and 49 items
  • Referred between 10 and 49 users
PrimaThemes says

Would you mind to elaborate more about this product “numbering”? And what is the purpose? I just to get better understanding in your goal for doing this.

Remember that rating is not integer, so you will get decimal number, 4.236 for example. And it is controlled by customer review, so you don’t have many control on this number.

145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

No, the numbering has nothing to do with the average rating. I just want a ranking for the products

So
1. Product number one (which has the most rating points) ...
description text

2. Product number two (which has the second most rating points …
description text

The only thing that I need is a FOR/WHILE loop that counts from 1 to X

The problem: I don’t really know where in the code I should put the loop and how to code it, so that it continues on page 2 with place 11/12… and on page 3 with 21/22/...

279 posts
  • Sold between 50 000 and 100 000 dollars
  • Exclusive Author
  • Has been a member for 1-2 years
  • Bought between 10 and 49 items
  • Referred between 10 and 49 users
PrimaThemes says

That is not difficult to do, but I am online from iPad now, can’t play with the code. :D let’s see if I can share something tomorrow.

145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

Thank you, that would be great. I know how to do it with blog posts (with the standard loop), but the woocommerce code is too complex for me.

145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

Anyone got a tip?

145 posts
  • Austria
  • Bought between 1 and 9 items
  • Exclusive Author
  • Has been a member for 1-2 years
LovelessDesign says

found a solution thanks.

by
by
by
by
by
by