XF 1.5 Profile Post Comment Conditional

Amaury

Well-known member
For posts and profile posts, I have a View Likes link that instantly takes you to the likes overlay.

Now that we've updated to 1.5, I'd like to do the same thing for profile post comments. I'm not seeing anything I can use for reference in the new profile_post_comment, but this is what I have in the profile_post template:

Code:
                    <xen:if is="{$profilePost.likes}">
                        <a href="{xen:link 'profile-posts/likes', $profilePost}" class="item control OverlayTrigger">{xen:phrase khflare_view_likes, 'count={xen:number $profilePost.likes}'}</a>
                    </xen:if>

Would adjusting it like so for comments be correct?

Code:
                    <xen:if is="{$profilePostComment.likes}">
                        <a href="{xen:link 'profile-posts/likes', $profilePostComment}" class="item control OverlayTrigger">{xen:phrase khflare_view_likes, 'count={xen:number $profilePostComment.likes}'}</a>
                    </xen:if>
 
Back
Top Bottom