On Jan 13, 2010, at 11:38 AM, Peter Degen-Portnoy wrote:

> Hi Folks,
> 
> I would greatly appreciate your thoughts on an approach we’re considering to
> solve a small design challenge.  Since this is our first Radiant
> install/build, we’re interested in picking up the entire radiant-fu from the
> get go.
> 
> We’ve identified that we can create four layouts for our entire site, one
> outer layout and three inner (using nested-layout, of course).  The majority

Are you first aware that Snippets have a r:yield tag allowing you to use them 
to wrap content? (example: <r:snippet name="x">my content or other 
code</r:snippet>
I've not personally used nested_layouts, but I find the concept of yielding 
content in a snippet to be easier to understand.

> of our pages will rely on one inner layout.  We have come up with a design
> scheme whereby content that is dynamically generated and therefore has code
> that would be confusing to an editor (radius tags, flow control, etc.) will
> be implemented as a snippet.  All other content will be implemented as page
> parts. 
> 
> There are two challenges we faced:
> 1. There is at least one page where we do not want to display at least one
> of the snippets called for in the most-used inner layout

Could you use r:if_url and r:unless_url ?

> 2. There are some page parts — different for each page — that should appear
> in a right gutter, wherein the rest are laid out in the left div.

if_content and unless_content allow for some serious flexibility. You can do:
 <r:if_content part="one, another, something_else" find="any">
        ... if any are found, the content will expand here...

See this post for info about it 
http://radiantcms.org/blog/archives/2008/08/01/new-flexible-features-in-standard-tags/

> 
> To solve Challenge 1, we thought of two schemes by which we can suppress the
> display of the targeted snippet:
> 1. Add a part called “No_<SNIPPET>” to the page where the targeted snippet
> should NOT be displayed

Yuck. I find that to be noise. It works, but editors of the content shouldn't 
have something they are told to ignore, which has been my experience with that 
approach.

> 2. Extend the snippet tag to have a new attribute “suppressable” so that a
> snippet that is flagged as “suppressable => true” has a check box generated
> & displayed on the /admin/page/x/edit view when the layout with that snippet
> is selected.  We can serialize the set of check boxes to support future
> expandability.
> 
> To solve Challenge 2, we also came up with two solutions:
> 1. Precede the name of a page part with “RG_” to indicate it should be
> displayed in the Right Gutter
> 2. Add a checkbox to the page part (after the reference links) “Display in
> Right Gutter” that would use similar display rules as described above.


What happens when you redesign your site and the RG contents are no longer in a 
"right gutter" location?

> 
> So, the question is, what clever solutions have you used to expand the Admin
> functionality for your users?  Is there another approach that we’re missing
> that would be more elegant?  I’d appreciate your warnings and
> encouragements.  :-)
> 
> Thanks,
> 
> Peter


Jim Gay
http://www.saturnflyer.com




_______________________________________________
Radiant mailing list
Post:   [email protected]
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

Reply via email to