Exclude tags from prev_post/next_post

Hey guys,

i just read the API reference for prev_post/next_post and saw that you can limit from where to pull. But I have not seen a way to exclude a certain (internal) tag. Is there a way?

I tried some things, including {{#prev_post in="-tag:[link,micro]"}}. But it didn’t work.

Thanks!

2 Likes

Hello @jbfriedrich. Did you ever manage to get this to work? Been fiddling around with this myself, although no success as of yet.

Hey @Stromfeldt. No, I never got it to work. I have limited JS knowledge, but it seems that one would need to change some Ghost code to extend the current behavior. I have changed my tagging strategy and re-tagged all my posts to achieve what I wanted to achieve.

1 Like

Ah, alright. I’ve already got Related Posts and Recent Posts sections, so I figure it might very well be overkill and so decided to just ditch the extra next/previous functionality. Thanks anyway!