X-Git-Url: http://git.subgeniuskitty.com/cmless/.git/blobdiff_plain/d955cfad358f87bc92b6f3cb2d1741e5dbb61cc5..0a58f7f180aedab31fdb9fdded7eaba1221893e4:/bin/template.py diff --git a/bin/template.py b/bin/template.py index c5b1d19..f27f493 100644 --- a/bin/template.py +++ b/bin/template.py @@ -7,12 +7,18 @@ import os # CMless imports import config, misc -def tpl_title(template): +def page_title(template): keyword = "page_title" return template.replace(config.template_delimiter + keyword + - config.template_delimiter, os.environ['REQUEST_URI']) + config.template_delimiter, config.site_name + " - " + + os.environ['REQUEST_URI']) -def tpl_body(template): +def site_title(template): + keyword = "site_title" + return template.replace(config.template_delimiter + keyword + + config.template_delimiter, config.site_name) + +def body(template): keyword = "page_content" body = misc.load_file(config.site_data_prefix + os.environ['REQUEST_URI'] + config.markup_file_extension)