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

XF 1.2 Style updates and template comparisons

Discussion in 'Styling and Customization Questions' started by Code Monkey, Sep 27, 2013.

  1. Code Monkey

    Code Monkey Well-Known Member

    How are style updates supposed to work with this new feature in XF 1.2?

    When updating a style I expected to get template change notices and would be able to merge them. Instead the old style was completely wiped out by the style update with no template changes listed. All changes were gone. I notice styles don't have version numbers. It's a real pain if this is how it is supposed to be.
     
  2. Russ

    Russ Well-Known Member

    Your best bet is to use a child style of whichever style your using and put all your customizations there.

    This way next upgrade... you'll overwrite the style you're using(parent) and the changes will trickle down to the child.

    If you've edited a template in the child, which was changed in the parent... the merge tool will help you merge the changes quickly.
     
  3. Code Monkey

    Code Monkey Well-Known Member

    Well it is a child of a framework. So how does that affect it? Update the framework only?
     
  4. Russ

    Russ Well-Known Member

    Well... not sure about @John 's framework but with ours we recommend the setup like this;

    • xenBase Framework
      • The Premium Style
        • Your Custom Style Name

    All changes should be in your custom style name, when we push out updates we usually try to only edit the framework however sometimes the actual style needs changes too, so both the framework and the style would need overwriting in that case.

    However I'm not sure what John updated in his release, it could be just the framework but you'd have to check with him.
     
  5. John

    John Well-Known Member

    All that was updated in the 1.2.2 release was one template in the framework.
     
    Russ likes this.
  6. Code Monkey

    Code Monkey Well-Known Member

    Yeah, I haven't asked him. I was more wondering about style functionality in Xenforo itself. Seems the new comparison ability is wasted here.
     
  7. Tracy Perry

    Tracy Perry Well-Known Member

    Shoot.. I jest be lazy... I always overwrite the base and the premium style... since mine is a child of the premium it'll warn me of any template changes I need to check out. :p
     
    Russ likes this.
  8. Russ

    Russ Well-Known Member

    That's ideal :D we love child styles
     
  9. Russ

    Russ Well-Known Member

    Its not wasted, for instance one template in the framework was updated, so you'd only overwrite the framework. You wouldn't need to overwrite the style itself.

    The merge tool comes in handy if you modified whichever template John updated in your style, you could then use the merge tool to merge his change with your change.

    Its a powerful tool once used right
     
  10. Code Monkey

    Code Monkey Well-Known Member

    Yes I know that. But if I update the framework then update the style it wipes out the style with all customizations. It seems to me that XF itself should preserve changed templates and give me a comparison and merge choice.
     
  11. Code Monkey

    Code Monkey Well-Known Member

    That's my point. It doesn't do that. If I update the style it wipes it clean and no old templates are there for comparison.
     
  12. Code Monkey

    Code Monkey Well-Known Member

    I should add that this happened on the update to 1.2 from 1.15. I am afraid to update it for 1.2.2 :D I guess it didn't need it anyway. lol
     
  13. Russ

    Russ Well-Known Member

    Sadly that's how the style system works, its why your best bet is to use child styles when it comes to dealing with styles from the resource manager.
     
  14. Code Monkey

    Code Monkey Well-Known Member

    Then the style system is dysfunctional sadly. That's how it should work and that's what I expected on the update.The style system needs to be updated to use the new comparisons directly IMO.

    Thanks for the feedback.
     
  15. Jeremy

    Jeremy XenForo Moderator Staff Member

    I'm not sure what you are talking about it 'needing to use the new comparisons directly'?
     
  16. Russ

    Russ Well-Known Member

    To be fair it's actually a really powerful system, as long as you take the appropriate steps(child style) your future updates will be a breeze.

    I think he wants it so when you import a style overwriting an existing one, it should go through and compare your edits with the style you're overwriting it with.
     
    Adam Howard likes this.
  17. Slavik

    Slavik XenForo Moderator Staff Member

    I don't quite get what your on about, when you update XenForo you will be given the option to compare...
     
  18. Code Monkey

    Code Monkey Well-Known Member

    Yes but then when you update the style when it's updated you don't get that. And I'm not "on about" anything and this is not a complaint. I am simply asking questions about XF so I can better understand what I need to do. That's what this forum is for right?
     
    Adam Howard likes this.
  19. Russ

    Russ Well-Known Member

    The problem he's talking about isn't updating XenForo, it's updating premium styles.
     
    Adam Howard likes this.
  20. Slavik

    Slavik XenForo Moderator Staff Member

    Aha I get you.
     

Share This Page