Template order (alphabetical displayname)

Enonic version: 6.6.2
OS: Mac and linux

If you have two templates for a content-type, for instance page.
And you create a new page.
The Page Template input box will say Automatic by default.

Which of the two templates Automatic selects, seems to be the alphabetical order of the template display name.

Would it be a good idea to define order somewhere?

You see our very seldom used page template happens to have a display name with lesser alphabetical value than the one we use all the time… :slight_smile:

Hi!

It actually uses the sorted order of the folder.
So if you change the order of the content in the folder to manual you can control this as you like today :grin:

1 Like

Nice is that documented anywhere?

Could not find it here:
http://xp.readthedocs.io/en/stable/admintools/contentstudio/page-templates.html?highlight=order

It’s on that page under the heading “Customizing content”

More than one page template can support the same content type. In this situation, the template that appears first in the Templates folder will be used to render the content by default. But individual content can be manually configured to use any template that supports its type. For example, in the image below there is a content type called “Post” and two templates that support the Post type, first is “Post show - 2 columns” and then “Post show - 1 column”. The “Post show - 2 columns” will be used automatically by all Post content. To force an individual Post content to use the 1 column template, edit the content and select the 1 column template in the Page Template dropdown at the top of the Inspect panel.

2 Likes

It’s official I’m blond :slight_smile: I meant blind.

3 Likes