Forum Discussion

kjartan's avatar
kjartan
Contributor
11 years ago

Add custom component only to topic post

What condition should one use in FreeMarker so that a costum component only shows up in the topic message post in a forum (the first post that is). I'm having some custom display of tags and was trying to use:

 

<#assign positionInThread=restadmin("/messages/id/${messageId}/position_in_thread").value>

To check whether it's the first post or not without any luck, since this only gives me the message I've clicked on in the thread.

 

Example: The first post in a thread has "Everyone's Tags:" but the other messages does not have this.

 

What I'm looking for is a simple if-statement to put in my costum component.

 

Thanks!

2 Replies