web/application.py
branchstable
changeset 2263 1f59cd5b710f
parent 1977 606923dff11b
child 2272 f27a3a75be0d
--- a/web/application.py	Fri Jul 03 18:02:24 2009 +0200
+++ b/web/application.py	Fri Jul 03 18:10:52 2009 +0200
@@ -404,8 +404,8 @@
         return self.vreg.main_template(req, template, view=view)
 
     def main_template_id(self, req):
-        template = req.property_value('ui.main-template')
-        if template not in self.vreg.registry('views') :
+        template = req.form.get('__template', req.property_value('ui.main-template'))
+        if template not in self.vreg.registry('views'):
             template = 'main-template'
         return template