Before making use of a certain template language, configure it in the Python Template Languages page of the Settings dialog.
- Open the project settings, and click the node Template Languages.
- In the Python Template Languages page, do the following:
- From the Template language drop-down list, select the specific template language to be used in project.
- In the Template file types area, specify the types of files, where template tags will be recognized.
Note that in HTML, XHTML, and XML files templates are always recognized.
Use Add and Remove buttons to make up the desired list of file types.
- Specify the directories where the templates in project will be stored.
To do that, open the Project Structure page, select a directory to be declared as a template directory, and click .
This command is duplicated on the context menu of a content root.
By default, the directory that has been defined as the templates folder on project creation , is marked as .
Note that if a directory is specified in the TEMPLATES_DIR of the settings.py file, then, on the first project opening, it is automatically marked as the template root.