XF 2.1 Style templates that have no master template

Mr Lucky

Well-known member
Please excuse the very basic questions.

I am wondering if you want to create a template (for example to include in another template) whether it's best practice to always create a master template and then edit each within the style, or is it OK to create a template purely in a specific style without creating a master?

I presume that if you intend to create several styles that all need that template then a master is useful, but if you only have one style then are there advantages or disadvantages in creating a master?

One more newb question:

If I create a master template, should I choose xenforo or blank as the addon?
 
If it's just for your own use on your own site, just create the template directly in the parent style(s).

If creating it as part of an add-on, don't use xenforo.
 
The master templates would usually be associated with an add-on of sorts, you wouldn't be able to export them on a style. Creating the template on the style level itself will export that custom template when you do the actual export.
 
Thanks, so it likes (as I am not making and addon) there is no adavantge to a master template.

If creating it as part of an add-on, don't use xenforo.
But if I was just creating it for my own site. e.g. if a i wanted a master template because I have several styles that ll use that, should I choose xenforo or just leave that blank?
 
If the template is designed so it's available on a setup like this:

  • Main Style
    • Color 2
    • Color 3
    • Color 4
You'd just create the template on the main style, not a master template.

If it's meant for a setup like this where you have multiple styles that aren't children of a main style:

  • Main Style
    • Color 2
  • Alt Style 1
    • Color 2 Alt style
  • Alt style 2
  • Alt Style 3

I'd recommend creating an add-on so the template is available to all styles (without having to create it in every single style) which you'd associate the template with the custom add-on (not xenforo).
 
Back
Top Bottom