Made template overriding more consistent and created template_overrides dir.
This commit is contained in:
parent
0729bf10b7
commit
df85edc295
2 changed files with 5 additions and 1 deletions
4
game/gamesrc/web/template_overrides/README.md
Normal file
4
game/gamesrc/web/template_overrides/README.md
Normal file
|
|
@ -0,0 +1,4 @@
|
||||||
|
Place your own version of templates into this file to override the default ones.
|
||||||
|
For instance, if there's a template at: `src/web/templates/evennia_general/index.html`
|
||||||
|
and you want to replace it, create the file `game/gamesrc/web/template_overrides/evennia_general/index.html`
|
||||||
|
and it will be loaded instead.
|
||||||
|
|
@ -514,7 +514,7 @@ STATICFILES_IGNORE_PATTERNS = ('README.md',)
|
||||||
ACTIVE_TEMPLATE = 'prosimii'
|
ACTIVE_TEMPLATE = 'prosimii'
|
||||||
# We setup the location of the website template as well as the admin site.
|
# We setup the location of the website template as well as the admin site.
|
||||||
TEMPLATE_DIRS = (
|
TEMPLATE_DIRS = (
|
||||||
os.path.join(GAME_DIR, "gamesrc", "web", "templates"),
|
os.path.join(GAME_DIR, "gamesrc", "web", "template_overrides"),
|
||||||
os.path.join(SRC_DIR, "web", "templates", ACTIVE_TEMPLATE),
|
os.path.join(SRC_DIR, "web", "templates", ACTIVE_TEMPLATE),
|
||||||
os.path.join(SRC_DIR, "web", "templates"),)
|
os.path.join(SRC_DIR, "web", "templates"),)
|
||||||
# List of callables that know how to import templates from various sources.
|
# List of callables that know how to import templates from various sources.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue