Forum for discussing general topics related to Couch.
2 posts Page 1 of 1
Hi,

I've a section in my nested_pages called "services" and wanted to pull the child pages from that parent into a block on the homepage and display them with:

Thubmnail, Title, Link, Excerpt and Link to the page

Is this possible?

I can get so far with my code below, I am using limit and paginate to limit how many are show (no pagination links) but the
Code: Select all
order='random'
doesn't work and I'm not sure if the page_image will (not set this up yet).

If there a better way to do this? I know it would be super easy using clonable pages, I have done this already to pull in a news feed of 5 most recent posts.

Code: Select all
            
<cms:nested_pages masterpage='index.php' childof='areas-of-practice' limit='4' paginate='1' order='random'>                  
<li class="span3">
   <a href="<cms:show k_nestedpage_link />">
      <img src="<cms:show page_image />" class="thumbnail" />
      <h5><cms:show k_nestedpage_title /></h5>
   </a>
</li>                  
</cms:nested_pages>      


Hi,

I think, except for the orderby='random', everything else should work just fine.
nested_pages supports only 'name', 'title', 'id', 'weight' as parameters for 'orderby'.

Please make sure to use include_custom_fields='1' with nested_pages as it, by default, does not fetch the custom-fields.
2 posts Page 1 of 1