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

Does "revert" work on custom templates?

Discussion in 'XenForo Questions and Support' started by CyclingTribe, Mar 24, 2011.

  1. CyclingTribe

    CyclingTribe Well-Known Member

    Just a query about the template revert feature.

    I installed the Flexile skin, and in the process of making a few changes of my own I had managed to make a mess of some of the CSS.

    To get me back-to-the-start I reverted all the templates in red, on the assumption that this would take me back to the base Flexite templates.

    However, this didn't work, so my query is - does reverting a template take it back to the code that the skinner supplies, or back to the default template code that comes with XF?

    Shaun :D
  2. Ryan Kent

    Ryan Kent Well-Known Member

    Reverting your template will cause your template to mirror the template of it's parent.

    If you have the Default install of XF, and you install Flexile as a child of XF, then reverting the template will cause it to revert back to the default template. In other words, you would lose all the Flexile changes.

    Erik lists out the recommended process in either the Flexile or Flexile Dark thread. You should install the Flexile style as a child of Default, then install your preferred color as a child of Flexile, and never touch the "Flexile" style. That way, your templates will not be overwritten during updates, and you can revert your templates as needed.

    Your install should look something like the below.

    Flexile Blue​
    Flexile Green​
    GeeksChat likes this.
  3. CyclingTribe

    CyclingTribe Well-Known Member

    Ah, good - glad I asked - because I failed to read that and installed it as a child of Default - which explains why it reverted back to XF instead of Flexile.

    /me slaps forehead!!! DOH!

    It also answers another question I was going to ask, which was "how does the parent / child relationship work in the template system?"

    Many thanks - I shall have another fiddle with the templates later this week.

    I reckon this advice will also save me muchos headaches in the future too, so +1 for the info.

    Shaun :D
  4. CyclingTribe

    CyclingTribe Well-Known Member

    Another quick query - can I "slot" Flexile in above the current style - make my current (customised) Flexile a child without having to remove it?

    Shaun :D
  5. Ryan Kent

    Ryan Kent Well-Known Member

    Not that I am aware of. My suggestion to you at this point (assuming you made custom modifications you do not wish to lose) is:

    Install a new copy of Flexile and name it "Flexile Template". Be certain to choose "Default" as it's parent and do NOT over-write your existing copy of Flexile.

    Next, install another copy of Flexile and name it "Flexile Blue". Make this copy a child of "Flexile Template" and again, do not over-write any existing copy.

    Copy over any template edits from your current Flexile, to Flexile Blue. Never ever make any edits to Flexile Template. Lastly, delete your current "Flexile" install.
    GeeksChat likes this.
  6. Brogan

    Brogan XenForo Moderator Staff Member

    You can change the heirarchy of a style at any time.
    Just click on the style name and select the Parent Style.
    Oracle and GeeksChat like this.
  7. CyclingTribe

    CyclingTribe Well-Known Member

    Thanks Gents ... that'll keep me on the right track. :)

Share This Page