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

RM widget

Discussion in 'XenForo Development Discussions' started by sadiq6210, Jan 20, 2016.

  1. sadiq6210

    sadiq6210 Active Member

    I wrote a small addon to display "RM stats" such as: Total RM downloads, Total RM files, Total RM category ...etc.

    I added the addon in forum sidebar and it is working perfect, but when I display it in RM home page, then all counters is showing Zero.

    To make it simple, I have a widget in forum homepage and I want to move it to RM homepage but when I did that, all counters became zero. Is there anything I need to do?
  2. Brogan

    Brogan XenForo Moderator Staff Member

    You would need to write code (PHP) to expose the data to the relevant template in the RM.
  3. sadiq6210

    sadiq6210 Active Member


    I will appreciate if you can give an example about how to write this code.
  4. wang

    wang Well-Known Member

    You must extend the XenResource_ControllerPublic_Resource class, and add your code inside the actionIndex() function.

Share This Page