Skip to content
● Grav 2.2 is out: 2x faster cold starts and 96% less memory on big sites. Read the announcement →

Can I limit the Amount of Tags shown on my Grav Site?

Solved by Pedro M View solution

Started by Kai 2 years ago · 6 replies · 359 views
2 years ago

I love Tags for Blog-Posts and use them a lot. But I experience the Issue when my page is floated by Tags on the right Side:

image|467x500

Theme is Open Quark Publishing.

Can I tell Grav/the Theme/the Taxonomy-Plugin that I only want X Tags there?
Are all of the Tags that I have created shown there?

2 years ago

And for Popular Tags I would expect the most used Tags and then only X of them. Like 10 or 20. But not all of the available ones 😃

2 years ago Solution

In quark/templates/partials/taxonomylist.html.twig change this line:

TWIG
{% for tax,value in taxlist[taxonomy]|slice(0,10) %}

Change the 10 to the number of tags you want to display.

2 years ago

I have inherited my used Theme now and will change it in the copied Twig-Template. That should solve it right?

👍 1
2 years ago

Okay, finally got my Child-Theme running thanks again @Karmalakas

And added the Taxonomy-Limit. Works. Thanks

Suggested topics

Topic Participants Replies Views Activity
General · by lynbor, 3 weeks ago
3 352 3 days ago
General · by lynbor, 1 week ago
7 386 3 days ago
General · by Harry, 3 days ago
0 83 3 days ago
General · by Old Man Umby, 3 weeks ago
2 256 2 weeks ago
General · by jeremycherfas, 3 weeks ago
5 374 2 weeks ago