Andrea Otto wrote:
> Hi,
> I'd like to know how can I use radiant at the best...
>
> For example: I have a Homepage with a lot of boxes with same graphic.
> How can I deploy this?
> *** snip ***
> So... How can I do it?
>
> My only working solution is to create a lot of childs page, all with a
> "mytext" part, put <r:snippet name="box"> in each body, create a snippet
> like this:
> <div class="foo">....
>  <r:content part="mytext">
> </div>
>
> and include all of my childs_box in the homepage with <r:child:each>
>
> Is it the right solution? Or there's a more pratic and fast modus
> operandi, like the first I exposed?
>   

Hi Andrea,

If you want to get:

<div class="foo">....
 <r:content part="mytext">
</div>

multiple times, I think the way I would do it would be to create an 
extension/ tag that would take your text as input and dump it out the 
way you want it.  I'm not sure that it's the best way to do it, but 
that's what comes to my mind right now.  I don't think (and I may be 
wrong) that you can pass parameters to a snippet like you can with Rails 
partials.

The other idea I have is that is this is required only on the home page, 
you may be able to cut down the reusability and just enter it into the 
body of the home page since in a sense, it's a "one-off".

Cheers,
Mohit.
9/18/2007 | 5:22 PM.


_______________________________________________
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