[Radiant] simple question about Radiant

Jim Gay jim at saturnflyer.com
Mon May 12 07:21:33 CDT 2008


On May 12, 2008, at 6:47 AM, Bartłomiej Frydrych wrote:

> hello,
> I have 2 questions about radiant:
> First:
> I have layout with sth like this:
> <div id="body-left">
>  <r:content />
> </div>
> <div id="body-right">
>  <r:content />
> </div>
>
> I make a Page and I want to put in body-left for example: Hello word!
> and to body-right: Hello Hello?
> how do this? becouse if I write sth it appears the same text in left  
> and
> right body
> what I should do to make it work?

make appropriate page parts. r:content defaults the the "body" part
<r:content part="your_part_name_here" />
There are some details about this here http://wiki.radiantcms.org/Using_Radiant

>
>
> And the second question:
> I have tree:
> -Home Page
>    - About
>       - 2008
>          - april
>          - march
>          - january
>      - 2007
>         - december
>         - march
>         - july
>         - april
>
> how to create a navigation in About page, that it will automaticly
> generate menu with years and months?
> like this:
> 2008
>  april
>  march
>  january
> 2007
>  december
>  march
>  july
>  april
> I have it now like this:
>
> <r:find url="/about">
>  <r:if_children>
>    <r:children:each>
>      <h3><r:link ><r:title/></r:link></h3>
>       <r:find url="/about/2008">
>        <r:if_children>
>
>          <r:children:each>
>           <r:link ><r:title/></r:link>
>          </r:children:each>
>
>        </r:if_children>
>      </r:find>
>    </r:children:each>
>  </r:if_children>
> </r:find>

You don't need that second r:find because you are already scoped to  
the "about" page, and r:link defaults to the page title

<r:find url="/about">
  <r:if_children>
    <r:children:each>
      <h3><r:link /></h3>
        <r:if_children>

          <r:children:each>
           <r:link />
          </r:children:each>

        </r:if_children>
    </r:children:each>
  </r:if_children>
</r:find>

I haven't really used Archive pages much, so off the top of my head I  
can't give you a code sample, but take a look at using Archive and  
ArchiveMonthIndex page types

-Jim




More information about the Radiant mailing list