We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 2790
    • 11 Posts
    Hello,

    I’m working on some manager module for Revolution in which I want to use custom Ext JS components. Sadly, these components require some additional CSS code but there does not seem to be a possibility to add CSS or JS code to the header of a page in the manager (at least not in alpha 3). Is there any way to do something like this WITHOUT hacking the manager templates (I want to package my module later) and, if not, could this be some useful feature to be added in the future?

    Regards,
    Thomas
      • 28215
      • 4,149 Posts
      Thomas,

      Well, you can always just link to the CSS/JS at the top of each .tpl you create, or even more - create a header.tpl in your component’s templates directory, and then use:

      {include file='header.tpl'}


      at the top of each page as a way of including it.

      Also, you can ’uncheck’ the Load Headers option in the action, and this will not load the header.tpl/footer.tpl, allowing you to provide your own.
        shaun mccormick | bigcommerce mgr of software engineering, former modx co-architect | github | splittingred.com
        • 2790
        • 11 Posts
        Hello,

        the second options seems to be the way to go as using the header.tpl file in my component with the standard manager templates will result in invalid HTML code when trying to include CSS therein as HTML does not allow use of the <link ... /> tag inside the body of a document.

        Regards,
        Thomas