CMS Development

Luon
Participante

Create a list of links to blog topics

resolver

Hi,

On my blog overview page i want to print a list of links to the blog topic pages.

Can someone please point me in the right direction?


Gr

Tim

1 Solução aceita
tjoyce
Solução
Especialista reconhecido(a) | Parceiro Elite
Especialista reconhecido(a) | Parceiro Elite

Create a list of links to blog topics

resolver

@Luon - 

That code can be found in the documentation. If you add a custom module or raw html block to your template, or even drop the following code into the source view of a wysiwyg on your page editor, you should get the list of topics and their links. It's important to keep in mind that orphaned topics that don't belong to a blog post will not show up.

{{ blog_topics('default', 250) }}

{% set my_topics = blog_topics('default', 250) %}
<ul>
{% for item in my_topics %}
<li><a href="{{ blog_tag_url(group.id, item.slug) }}">{{ item }}</a></li>
{% endfor %}
</ul>

If this answer helped, please, mark as solved 😄


tim@belch.io | forms.belch.io | Design your own Beautiful HubSpot Forms; No coding necessary.

Exibir solução no post original

2 Respostas 2
tjoyce
Solução
Especialista reconhecido(a) | Parceiro Elite
Especialista reconhecido(a) | Parceiro Elite

Create a list of links to blog topics

resolver

@Luon - 

That code can be found in the documentation. If you add a custom module or raw html block to your template, or even drop the following code into the source view of a wysiwyg on your page editor, you should get the list of topics and their links. It's important to keep in mind that orphaned topics that don't belong to a blog post will not show up.

{{ blog_topics('default', 250) }}

{% set my_topics = blog_topics('default', 250) %}
<ul>
{% for item in my_topics %}
<li><a href="{{ blog_tag_url(group.id, item.slug) }}">{{ item }}</a></li>
{% endfor %}
</ul>

If this answer helped, please, mark as solved 😄


tim@belch.io | forms.belch.io | Design your own Beautiful HubSpot Forms; No coding necessary.

Luon
Participante

Create a list of links to blog topics

resolver

Thank you very much!