[Zope] progammatically add a Page Template

Mark McEahern mark@mceahern.com
Mon, 30 Sep 2002 08:51:15 -0500


[Felix Ulrich-Oltean [mailto:felix@chaptereight.com]]
> Something like this should work in a python script:
> 
> folder.manage_addProduct['PageTemplates'].manage_addPageTemplate('
> newTemplateId',
> title='My Shiny New Template')
> 
> If you're writing a python product, you can do it by importing
> Products.PageTemplates.ZopePageTemplate and using something shorter
> like:
> 
> ZopePageTemplate.manage_addPageTemplate(folder, id, title, etc...)

Thanks for the suggestion, Felix.

Cheers,

// mark
-