Blog module listing on topic - Can't find tag

SOLVE
AxelS
Contributor

Hi,

We have a Blogg module that displays blogtopics. It is based on the topics tags. 

{% set posts = blog_recent_topic_posts(module.select_blog_or_case, module.select_topic, module.offset|add(4)) %}

In the module I know that I have to replace space with _  in order for it to work. But I have a tag with an ampersand (&) in it. It seems this makes the module unable to retrieve the right blogposts. Is there something I need to replace the ampersand with or do I have to simply avoid them in tags alltogether.


0 Upvotes
1 Accepted solution

Accepted Solutions
amwilie
Solution
Key Advisor | Elite Partner

Hey @AxelS 

Can you go to the topic page and see what the URL is outputting the & as (this would be the tag slug)? And then try using module.select_topic|replace('&','_') ; just replace _ with whatever the & is being replaced with in the slug.

 

Alyssa Wilie
Web Developer
LyntonWeb

Alyssa Wilie

Web Developer at LyntonWeb

If this answer solved your question, please mark it as the solution!

View solution in original post

2 Replies 2
amwilie
Solution
Key Advisor | Elite Partner

Hey @AxelS 

Can you go to the topic page and see what the URL is outputting the & as (this would be the tag slug)? And then try using module.select_topic|replace('&','_') ; just replace _ with whatever the & is being replaced with in the slug.

 

Alyssa Wilie
Web Developer
LyntonWeb

Alyssa Wilie

Web Developer at LyntonWeb

If this answer solved your question, please mark it as the solution!

View solution in original post

AxelS
Contributor

Thank you! It worked perfectly 🙂

0 Upvotes