• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Add-on not working after XF upgrades, has to be reinstalled

karll

Well-known member
#1
Except for my lack of talent, what could be the reason I need to reinstall my add-on after every XF upgrade?
 

Chris D

XenForo developer
Staff member
#4
Your watch_threads_all template is being overwritten during upgrades which is exactly the expected behavior. To modify core templates, you don't just overwrite them in your add-on.

You're supposed to use template hooks or similar to inject your changes into the existing template.
 

karll

Well-known member
#5
Your watch_threads_all template is being overwritten during upgrades which is exactly the expected behavior. To modify core templates, you don't just overwrite them in your add-on.

You're supposed to use template hooks or similar to inject your changes into the existing template.
Thanks muchly for this. However, there doesn't appear to be any hooks in the watch_threads_all template ... What can I do then?
 

Chris D

XenForo developer
Staff member
#8
Yeah, the TM system is much more appropriate now.

Aside from that, though, you can also try the template_post_render event which allows you to modify the rendered template directly in PHP. Very similar to template hooks.

But it's great that we don't have to use those anymore :)