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

XF 1.2 How do I make template changes that will affect all styles?

Discussion in 'XenForo Questions and Support' started by Lone Wolf, Jan 6, 2014.

  1. Lone Wolf

    Lone Wolf Well-Known Member

    I have 3 styles installed and I'm thinking of increasing this to 5 styles when I upgrade to 1.2

    However there are a few template edits which I make in every style, these edits are to the same same template and are the same edits in each style. For example a sticky seperator, extra menu options, etc.

    Is there a way I can make these edits in one place where it will affect all the styles. This would make things a lot easier and less time intensive.

    Can it also be done for style properties too?
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    The only way it can be done is by making the other two styles children of the parent style.

    Then any changes will be inherited, unless the child styles themselves have modified those templates or SPs.
     
  3. RoldanLT

    RoldanLT Well-Known Member

    Then better use Template Modification, enable debug mode first. That's what i did since XenForo intruduce it.
     
    Lone Wolf likes this.
  4. Lone Wolf

    Lone Wolf Well-Known Member

    Yes but wont that mean the child styles inherit the parent style. Sounds like a mess since Flexile already uses itself as a parent style so i would be having 3 layers of styles.

    That sounds interesting, how do I do that?
     
  5. Brogan

    Brogan XenForo Moderator Staff Member

  6. Lone Wolf

    Lone Wolf Well-Known Member

  7. RoldanLT

    RoldanLT Well-Known Member

    Yeah, that's it. :)
     
  8. Lone Wolf

    Lone Wolf Well-Known Member

    This works for extra.css as well?

    Any way to do the same for style properties? Eg, header, etc
     
  9. Lone Wolf

    Lone Wolf Well-Known Member

    I clicked on Template modifications but there is no create new template modification option. Do I have to be in debug mode?
     
  10. Brogan

    Brogan XenForo Moderator Staff Member

    If you want the button available, yes.

    Otherwise just navigate to admin.php?template-modifications/
     
    Lone Wolf likes this.
  11. Lone Wolf

    Lone Wolf Well-Known Member

    That takes me to the same page with no buton. Let me try debug
     
  12. Lone Wolf

    Lone Wolf Well-Known Member

    It works with debug mode. Thanks
     
  13. katsulynx

    katsulynx Well-Known Member

    yourpage.com/admin.php?template-modifications/add gives you direct access and the possibility to create modifications even when not in debug mode.
     
  14. RoldanLT

    RoldanLT Well-Known Member

    But then you cannot modify.
     
  15. Jeremy

    Jeremy XenForo Moderator Staff Member

    template-modifications/1/edit, etc. should allow you to edit.
     
  16. RoldanLT

    RoldanLT Well-Known Member

    The form is read only I think.
     
  17. Lone Wolf

    Lone Wolf Well-Known Member

    Ok I've run into an issue. I wanted to remove the staff online box across all styles by adding the following to extra.css

    Code:
    .sidebar .staffOnline {
      display: none;
    }
    But it doesn't work unless it's finding and replacing text. You cant use it to add some code to a specific template in all styles.
     

Share This Page