APIs & Integrations

Not applicable

Using topic.name in a blog listing

I have a blog listing page that displays the topics name above the listing. I have done this by simply using {{ topic }} however this seems to output the slug rather than the name. I have tried using {{ topic.name }} as referenced at the bottom of the page here http://designers.hubspot.com/docs/hubl/hubl-supported-variables however it then does not output anything.

How can I output the topics name on the listing page?

0 Upvotes
4 Replies 4
Derek_Gervais
HubSpot Alumni
HubSpot Alumni

Using topic.name in a blog listing

Hi @MikeyWallis,

{{ topic.name }} should work; can you direct message me a link to the blog you’re working on so I can take a closer look?

0 Upvotes
elmo
Contributor

Using topic.name in a blog listing

topic.name still doesn't work. It outputs nothing. Neither does topic.slug. Only topic works, and it just outputs the slug.

 

Currently we circumvent this by using page_meta.html_title|replace(group.html_title ~ ' | ', ''), which uses the topic page's title and strips the site title away from it, but it just feels silly. Maybe a fix to this bug should already be in order?

 

(While you're at it, could you also fix the content.publish_date, which doesn't work for pages, only for blog posts.)

davidecepar
Participant | Diamond Partner
Participant | Diamond Partner

Using topic.name in a blog listing

Hi, thanks for that solution but also the replace isn't working in my case. Any idea?

0 Upvotes
Not applicable

Using topic.name in a blog listing

Thanks Derek, inboxed you.

0 Upvotes