soc/templates/README.templates
author Todd Larsen <tlarsen@google.com>
Wed, 21 May 2008 16:27:35 +0000
changeset 31 8b43c541afa7
parent 3 962da9e1065d
child 34 14c266e01a56
permissions -rw-r--r--
First iteration of a "prototype" Melange app, along with an initial Person Profile view. Patch by: Augie Fackler (with some additions by Todd Larsen) Review by: Todd Larsen Review issue: 46 Review URL: http://codereviews.googleopensourceprograms.com/46

Templates are placed in a "namespace" subdirectory in the templates directory,
since the templates directory will be added to the Django templates search
path.  This allows other packages to extend existing templates without "hiding"
the original template.  For example, a template in another Melange application
can extend a template in the SoC framework like this:

  {% extends 'soc/some_existing_template.html %}

without "hiding" the some_existing_template.html for other uses, even if the
derived template is also named some_existing_template.html.

So, please do not put any templates in this soc/templates directory, but only
place them in the soc/templates/soc "namespace" subdirectory.

Different Melange applications should also follow this pattern, to promote
sharing of templates between applications as well.  For exmample, the GSoC
Melange application should place its templates in gsoc/templates/gsoc.