XF 2.2 Event listener not working when hint is specified

GPA-R

Active member
Hi,

I have created an event listener for event "templater_template_post_render" with a callback function in my addon.

The callback works as expected, however I want only the message of a post/thread to be filtered. I tried using public:post_macros:post_user_content as a hint but it doesn't work.

Any...hints what could be the issue? (Ok obviously I am using the wrong event hint but I don't know how to get the right one - based on what I've read the above should be correct?).

public:PAGE_CONTAINER still replaces everything and I haven't figured if there's anything inside that can narrow down the selection.

Thanks in advance
 
Last edited:
Based on your explanation, you're using the template post-render event, but entering a macro name in the hint. It sounds like you want to use templater_macro_post_render with that hint.

(It's worth also noting that post_macros is never directly rendered, so it'd never hit templater_template_post_render.)
 
Back
Top Bottom