A new template in Umbraco will not appear in the Templates drop-down list on content pages

Another Umbraco question, apologies. I created a new template in the master template list, but this template does not appear in the Templates drop-down list on content pages. I am wondering if there is something that I missed, or if there is a way to post this, which is not immediately obvious.

Any help was appreciated.

+4
source share
2 answers

You need to choose a template as a valid template type for the document type of your pages. Suppose you are a Document Type page called "ContentPage" and you have added a new template called "NewTemplate".

By default, you cannot select a new template when editing the "ContentPage" pages. You will need to go to “Settings” in Umbraco and then expand the “Document Types” folder. You will see a list of all types of documents, select the one you want to use in the template ("ContentPage" in this example).

The first tab you will see is the Information tab. There is a checkbox "Allowed templates" in which you need to select a new template. Save the document type and return to the Content. Now you can select "NewTemplate" as a template on your "ContentPage" pages on the site!

+10
source

I hesitate to participate in thread nitromancy, but since this is the first result of Google, and it seems to be in 7.4.3 (the first version of Umbraco that I have ever experienced), I would like to share the process I use to add templates to document types.

  • Go to Settings.
  • Expand "Document Types" and select the type of document to which you want to apply the template.
  • Click "Templates" in the upper right corner of the page.
  • Click "Choose an additional template."
  • Select the template you want to allow and click Close.
  • Click "Save."
  • Go to "Content."
  • Now you can create new content under the type of document that you selected, with the template you specified.

I hope this helps save another new Umbraco dev that will scratch my head a bit.

+2
source

Source: https://habr.com/ru/post/1439358/


All Articles