Popular recipes tagged "template" but not "macro"http://code.activestate.com/recipes/tags/template-macro/2013-06-21T14:47:21-07:00ActiveState Code RecipesEasy to use, easy to read, python based HTML generation (Python)
2013-06-21T14:47:21-07:00Pavloshttp://code.activestate.com/recipes/users/4185038/http://code.activestate.com/recipes/578436-easy-to-use-easy-to-read-python-based-html-generat/
<p style="color: grey">
Python
recipe 578436
by <a href="/recipes/users/4185038/">Pavlos</a>
(<a href="/recipes/tags/html/">html</a>, <a href="/recipes/tags/template/">template</a>, <a href="/recipes/tags/text/">text</a>).
Revision 4.
</p>
<p>I was looking for a simple way to generate HTML directly in python that does not require learning a new template 'language' nor requires the installation of a big complex package. Closest thing I found was James Casbon's attempt(https://gist.github.com/1461441). This is my version of the same idea. </p>
<p>(2013-04-21) added some simplifications and support for switching off string interpolation. Added to github:</p>
<p><a href="https://github.com/pavlos-christoforou/web" rel="nofollow">https://github.com/pavlos-christoforou/web</a></p>
Cheetah template processor for CSV and XML data (Python)
2010-05-21T10:00:14-07:00Raphaël Jolivethttp://code.activestate.com/recipes/users/4135673/http://code.activestate.com/recipes/577234-cheetah-template-processor-for-csv-and-xml-data/
<p style="color: grey">
Python
recipe 577234
by <a href="/recipes/users/4135673/">Raphaël Jolivet</a>
(<a href="/recipes/tags/cheetah/">cheetah</a>, <a href="/recipes/tags/csv/">csv</a>, <a href="/recipes/tags/merge/">merge</a>, <a href="/recipes/tags/populate/">populate</a>, <a href="/recipes/tags/template/">template</a>, <a href="/recipes/tags/xml/">xml</a>).
</p>
<p>This script allows to populate Cheetah text templates (<a href="http://www.cheetahtemplate.org/" rel="nofollow">http://www.cheetahtemplate.org/</a>) with XML or CSV input data.</p>
<p>This is useful in my day2day work, where I often need to quickly generate bunch of files based on a templates and data.</p>
<p>Cheetah template are very easy to write and understand, and I find it easy to use with CSV or XML data.</p>
Userfriendly Webpage Template (Python)
2010-05-04T07:38:03-07:00david.gaarenstroomhttp://code.activestate.com/recipes/users/4168848/http://code.activestate.com/recipes/577203-userfriendly-webpage-template/
<p style="color: grey">
Python
recipe 577203
by <a href="/recipes/users/4168848/">david.gaarenstroom</a>
(<a href="/recipes/tags/cgi/">cgi</a>, <a href="/recipes/tags/html/">html</a>, <a href="/recipes/tags/httpserver/">httpserver</a>, <a href="/recipes/tags/mvc/">mvc</a>, <a href="/recipes/tags/template/">template</a>, <a href="/recipes/tags/web/">web</a>, <a href="/recipes/tags/webdesign/">webdesign</a>, <a href="/recipes/tags/webpagetemplate/">webpagetemplate</a>).
Revision 5.
</p>
<p>User friendly template class targeted towards Web-page usage and optimized for speed and efficiency.</p>
<p>Tags can be inserted in a template HTML file in a non-intrusive way, by using specially formatted comment strings. Therefore, the template-file can be viewed in a browser, even with prototype data embedded in it, which will later be replaced by dynamic content.
Also, webdesigners can continue to work on the template and upload it without further
modification.</p>
Basic class code generator (Python)
2010-03-22T10:58:19-07:00Mateyuzohttp://code.activestate.com/recipes/users/4172453/http://code.activestate.com/recipes/577130-basic-class-code-generator/
<p style="color: grey">
Python
recipe 577130
by <a href="/recipes/users/4172453/">Mateyuzo</a>
(<a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/prototyping/">prototyping</a>, <a href="/recipes/tags/template/">template</a>).
Revision 5.
</p>
<p>This little script takes a yaml file as a class definition and generates code stubs and unit tests.</p>
Templite+ (Python)
2009-02-28T04:44:46-08:00Thimo Kraemerhttp://code.activestate.com/recipes/users/4169283/http://code.activestate.com/recipes/576663-templite/
<p style="color: grey">
Python
recipe 576663
by <a href="/recipes/users/4169283/">Thimo Kraemer</a>
(<a href="/recipes/tags/template/">template</a>, <a href="/recipes/tags/templating/">templating</a>, <a href="/recipes/tags/text/">text</a>).
Revision 13.
</p>
<p>Revised version of <a href="http://code.activestate.com/recipes/496702/">Templite</a>, a light-weight, fully functional, general purpose templating engine</p>