[Radiant] Changing page layout on-the-fly?

2009-07-16 Thread Mamed Mamedov
Hi everybody! I have a little question: how can I change page's layout from within my extension? Problem is, that I have 2 different page layouts for my site: [ full-version and light-version ]. I want to write a mini-extension to switch between designs of my site throw hitting: /design/set/full

Re: [Radiant] Changing page layout on-the-fly?

2009-07-16 Thread Petrik de Heus
On Jul 16, 2009, at 13:01 , Mamed Mamedov wrote: Hi everybody! I have a little question: how can I change page's layout from within my extension? Something like this: def activate Page.class_eval do def process_with_session_layout(request, response) self.layout =

Re: [Radiant] Changing page layout on-the-fly?

2009-07-16 Thread Sean Cribbs
If all of your pages have the same layout at any time, make sure all descendant pages have their layout set to inherit and then your extension could change the layout on the root page. However, it would not be trivial to do this on a per-user basis. Have you considered something like a