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

XF 1.3 Which way is better for styling ?

Discussion in 'Styling and Customization Questions' started by tonnyz, Nov 14, 2014.

  1. tonnyz

    tonnyz Member

    Hi, I'm having a lot of stylings and customizations on my forum.

    Let's say that the customizations have 3 viable methods, which one is the best (most recommended) and which one is the worst (not recommended) ?

    1. piling them in extra.css by typing the scripts directly

    2. using template modification to modify extra.css

    3. editing style properties

    thx :)
     
  2. Brogan

    Brogan XenForo Moderator Staff Member

    1 and 3 are your choice.
    2 isn't a valid method - there is no point using TMs on EXTRA.css as it is never changed or updated during an upgrade.

    The other options are to edit the templates directly or apply TMs to the templates.
     
  3. tonnyz

    tonnyz Member

    @bold: Just reassuring, do you mean that if I type in extra.css
    Code:
    .quickReply .messageUserInfo .helper {
    display:none;
    }
    then I upgrade to a newer version that changes the (let's say) .messageUserInfo >>> .postUserInfo

    the code in extra.css will also automatically change to :
    Code:
    .quickReply .postUserInfo .helper {
    display:none;
    }
    CMIIW
     
  4. Amaury

    Amaury Well-Known Member

    No, you'll need to manually adjust it accordingly.
     
  5. Brogan

    Brogan XenForo Moderator Staff Member

    Why would you want your custom CSS to update to the new code when upgrading?

    It that is the case, why bother having any custom CSS?

    Any changes to the HTML in terms of classes used would require you to make the corresponding changes.
     
  6. tonnyz

    tonnyz Member

    ooh, I see


    No, I don't hope for the automatic update either.

    I asked that in regard to your post here
    v
    v
    v
    So, what will actually be changed / updated (during an upgrade) if I work directly in extra.css ?
     
  7. Brogan

    Brogan XenForo Moderator Staff Member

    Nothing.

    EXTRA.css is never changed.
     
  8. tonnyz

    tonnyz Member

    err... so, what is the bold part refer to ? If the scripts remain equally unchanged during an upgrade, what is the unchanged part you are talking about?

    sorry sir , I still don't catch it :confused:
    v
    v
    v
     
  9. Brogan

    Brogan XenForo Moderator Staff Member

    I'm really not following you.

    EXTRA.css is a blank template for you to apply your own styling customisations to.

    It is never changed during an upgrade.
    Whatever you add there will remain indefinitely.
     
  10. tonnyz

    tonnyz Member

    Still referring to this bold part
    v
    v
    v
    did you mean that the TMs on extra.css will lose their effect after upgrading ?

    CMIIW
     
  11. Brogan

    Brogan XenForo Moderator Staff Member

    No.
    I'm saying don't use TMs on EXTRA.css as it is pointless.
     
  12. tonnyz

    tonnyz Member

    and you said that it is pointless since it is never changed or updated during an upgrade, didn't you.

    So my question is: what are you referring to with "it is" ?
     
  13. Brogan

    Brogan XenForo Moderator Staff Member

    I'm really not following you at all.

    I don't know how else I can explain it.
     
    tonnyz likes this.
  14. tonnyz

    tonnyz Member

    ok, nevermind, sorry sir I'm new around here :)

    I'll just take that it'll be better for modifying directly on extra.css then

    Just another question, will it be a trouble if I pile too many scripts on extra.css ?
     
  15. Brogan

    Brogan XenForo Moderator Staff Member

    Yes, just add your code directly to EXTRA.css.
    That is how it is intended to be used.

    You can add many thousands of lines of code to it without issue.
     
    tonnyz likes this.
  16. Amaury

    Amaury Well-Known Member

    As long as they're proper and you don't have any broken code, for example, you shouldn't have any problems.
     
    tonnyz likes this.
  17. tonnyz

    tonnyz Member

    Thanks for your support, sir (y)

    still baffled with the "unchanged part" though, but nevermind for that :LOL:
     

Share This Page