# Adding "extended" content to existing page?

**URL:** <https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678>\
**Category:** Radiant CMS\
**Created:** [November 12, 2006, 8:45am UTC](https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678 "2006-11-12T08:45:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brian\_Capouch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bc79bd/32.png) [@Brian\_Capouch](https://www.ruby-forum.com/u/Brian_Capouch)\
**Post date:** [November 12, 2006, 8:45am UTC](https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678/1 "2006-11-12T08:45:23Z")

</div>

Newb here. Doing my best. I’ve spent many hours trying to figure this  
one out, so far w/o success.

Is there any way to “extend” an article once it’s written.

By that, I mean to show only the first part of it and let the “Archive”  
parent page print that part and then provide a “Read more” link.

I used the default site provided with the gem install, and then edited  
the resulting pages.

I didn’t notice until afterwards that while _new_ child pages I create  
under the main Articles page have both “Body” and “Extended” parts, the  
existing pages (which I edited) did not.

I’m confused as to who decides that gets put there, and how, and whether  
it is changeable after the fact.

Thanks for any pointers I might elicit.

B.

–  
This message has been scanned for viruses and  
dangerous content by MailScanner, and is  
believed to be clean.

---

<div class="post-metadata">

**Author:** ![Brian\_Capouch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bc79bd/32.png) [@Brian\_Capouch](https://www.ruby-forum.com/u/Brian_Capouch)\
**Post date:** [November 12, 2006, 2:29pm UTC](https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678/2 "2006-11-12T14:29:48Z")

</div>

Brian,

Yes, that is one of the basic things that the “Styled Blog” template  
does. Essentially you have this on the page that only displays part of  
the article:

\<r:children:each\>  
…  
\<r:content /\>  
\<r:if\_content part=“extended”\>\<r:link\>Read  
more…\</r:link\>\</r:if\_content\>  
\</r:children:each\>

That loops through the child pages of the current page, displaying the  
“body” part (that’s the \<r:content /\> tag), then a link if the  
“extended” page-part exists. On the child page, you’d display both the  
“body” and “extended” parts.

Sean C.  
[seancribbs.com](http://seancribbs.com)

---

<div class="post-metadata">

**Author:** ![Brian\_Capouch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bc79bd/32.png) [@Brian\_Capouch](https://www.ruby-forum.com/u/Brian_Capouch)\
**Post date:** [November 13, 2006, 6:05pm UTC](https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678/3 "2006-11-13T18:05:33Z")

</div>

> I didn’t notice until afterwards that while _new_ child pages I create  
> under the main Articles page have both “Body” and “Extended” parts,  
> the  
> existing pages (which I edited) did not.
> 
> I’m confused as to who decides that gets put there, and how, and  
> whether  
> it is changeable after the fact.

You get to decide which pages have which parts yourself. If a page  
has only a “body” part, edit the page look for the green-circled “+”  
sign at the top-right corner of the content editing area. Click that  
to add a new page part. In the “Add Part” dialog that pops up enter  
the name “extended” and click the “Add Part” button.

- Sean

---

<div class="post-metadata">

**Author:** ![Brian\_Capouch](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bc79bd/32.png) [@Brian\_Capouch](https://www.ruby-forum.com/u/Brian_Capouch)\
**Post date:** [November 13, 2006, 6:21pm UTC](https://www.ruby-forum.com/t/adding-extended-content-to-existing-page/75678/4 "2006-11-13T18:21:36Z")

</div>

> I didn’t notice until afterwards that while _new_ child pages I create
> 
> > under the main Articles page have both “Body” and “Extended” parts,  
> > the  
> > existing pages (which I edited) did not.
> > 
> > I’m confused as to who decides that gets put there, and how, and  
> > whether  
> > it is changeable after the fact.

You can change which Parts are default in the database - config table,  
default.parts field.

-Todd M
