# Extended content in distributed example

**URL:** <https://www.ruby-forum.com/t/extended-content-in-distributed-example/83681>\
**Category:** Radiant CMS\
**Created:** [January 28, 2007, 8:09pm UTC](https://www.ruby-forum.com/t/extended-content-in-distributed-example/83681 "2007-01-28T20:09:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Anton\_J\_Aylward](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/e495f1/32.png) [@Anton\_J\_Aylward](https://www.ruby-forum.com/u/Anton_J_Aylward)\
**Post date:** [January 28, 2007, 8:09pm UTC](https://www.ruby-forum.com/t/extended-content-in-distributed-example/83681/1 "2007-01-28T20:09:28Z")

</div>

In the distribution example, the Home Page has a line of code

\<r:if\_content part=“extended”\>  
\<r:link anchor=“extended”\>  
Continue Reading…  
\</r:link\>  
\</r:if\_content\>

(Its one one line in the example)  
Since its in the context of the ‘child’ I presume it refers to the  
child.

When viewed as the web site I’m prototyping this has a link to

[http://server:3000/presentations/2007/01/27/jan-27th-event/#extended](http://server:3000/presentations/2007/01/27/jan-27th-event/#extended)

However when I click on that link I get take to a page that has that in  
the  
address bar but is identical to  
[http://server:3000/presentations/2007/01/27/jan-27th-event](http://server:3000/presentations/2007/01/27/jan-27th-event)

That is: the content I put in the ‘extended’ tab that I created for that  
for  
that page doesn’t appear. Actually I’m surprised the base page appears!

What am I doing wrong or misunderstanding?

–  
“A Meltdown? One of those annoying buzzwords. We prefer to think of it  
as an  
unrequested fission surplus!”  
– Monty Burns

---

<div class="post-metadata">

**Author:** ![Anton\_J\_Aylward](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/e495f1/32.png) [@Anton\_J\_Aylward](https://www.ruby-forum.com/u/Anton_J_Aylward)\
**Post date:** [January 28, 2007, 8:13pm UTC](https://www.ruby-forum.com/t/extended-content-in-distributed-example/83681/2 "2007-01-28T20:13:29Z")

</div>

Anton J Aylward wrote:

> Since its in the context of the ‘child’ I presume it refers to the child.  
> that page doesn’t appear. Actually I’m surprised the base page appears!
> 
> What am I doing wrong or misunderstanding?

In the layout of your child page (which might be the same as the parent)  
you need to render the “extended” part. So somewhere in the layout, you  
should find something like this:

\<r:content /\>  
\<r:if\_content part=“extended”\>

The first line renders the “body” part, then, if there is an “extended”  
part, it is rendered inside a div with an anchor named “extended”.

Sean

---

<div class="post-metadata">

**Author:** ![Anton\_J\_Aylward](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/e495f1/32.png) [@Anton\_J\_Aylward](https://www.ruby-forum.com/u/Anton_J_Aylward)\
**Post date:** [January 28, 2007, 9:31pm UTC](https://www.ruby-forum.com/t/extended-content-in-distributed-example/83681/3 "2007-01-28T21:31:40Z")

</div>

Sean C. said the following on 01/28/2007 02:14 PM:

> \</r:if\_content\>
> 
> The first line renders the “body” part, then, if there is an “extended”  
> part, it is rendered inside a div with an anchor named “extended”.

So it wasn’t me, the distributed example was buggy.

I can see that will render the extended part as well as body.  
I’m confused!

I’ve just set up Mental along side the Radiant-0.5.2  
In the out of the box Mental adding a ‘extended’ tab to ‘First Post’  
results in  
The parent blog format shows third, second and first posts  
The parent view has ‘first post’ showing:

```
     First Post

    This post uses textile.
    Continue Readingâ€¦ <-- LINK

    Posted by on Jun 09, 2006

The link is to 

```

[http://server:3000/articles/2006/06/09/first-post/#extended](http://server:3000/articles/2006/06/09/first-post/#extended)  
Clicking on the link takes me to ‘first post’  
which shows.

```
    First Post

    This post uses textile.
    This is extended content

    Posted by on Friday, June 09, 2006

Which (a) is not what I expected because (b)
the main part *and* the extended content are shown.
I don't see anything that would cause this.

```

The side-by-side 0.5.2 doesn’t behave that way.  
clicking on the ‘Continue reading’ link brings up, as I said, a page  
with  
that same url, but is not displaying _either_ the extended content _or_  
the  
main body.

REPEAT: Mental and 0.5.2. have different behaviours  
REPEAT: I don’t think either behaviour is correct.

This doesn’t make sense to me.  
In the layout the code to display the sidebar doesn’t cause the main  
body to  
be displayed in the sidebar.

I continue to be confused but am coming to believe the problem  
is not my ignorance though it may be my assumptions.

–  
/anton  
Cats regard people as warm-blooded furniture. --Jacquelyn Mitchard
