This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
devel:blueprints:django_template [2010/01/13 10:00] eide |
devel:blueprints:django_template [2010/01/13 10:06] eide code tags |
||
---|---|---|---|
Line 9: | Line 9: | ||
Compability with Django templates are done seamless. The MainTemplate includes nav.webfront.compability.Cheetah which provides two methods called footer and header. These two methods are simply printed, and thus the header and footer appears. | Compability with Django templates are done seamless. The MainTemplate includes nav.webfront.compability.Cheetah which provides two methods called footer and header. These two methods are simply printed, and thus the header and footer appears. | ||
+ | ==== Additional <head> content ==== | ||
+ | If a subsystem that uses Cheetah wants additional meta/CSS/JavaScript and/or other content that should go in the HTML head section to work it must appear in a subclass of one of the "additional" methods defined in the MainTemplate. | ||
+ | |||
+ | The methods are: additionalMeta, additionalCSS, additionalJavaScript, additionalHead. | ||
+ | |||
+ | Ie. if a subsystem wants to use foobar.css, it must appear in additionalCSS as such: | ||
+ | |||
+ | <code> | ||
+ | #def additionalCSS | ||
+ | <link rel="stylesheet" type="text/css" href="foobar.css" /> | ||
+ | #end def additionalCSS | ||
+ | </code> |