Problems, need help? Have a tip or advice? Post it here.
3 posts Page 1 of 1
I have a team member page for a website that the client wants to display the Folder Name and the relevant Team Members underneath. I need it to be dynamic in case they change the folder names or add folders etc. I am not quite sure with the code below how to display only the team members within a folder. Is there a way to accomplish this?

<cms:pages masterpage='team.php' folder=k_page_foldertitle orderby=k_page_foldertitle >
<cms:set my_loop_count="<cms:zebra '1' '2' '3' '4' />" 'global' />

<cms:if my_loop_count='1'>
<div class="row">
<div class="gap"></div>
<h2><cms:show k_page_foldertitle /></h2>
<div class="team-gap"></div>
</cms:if>
<div class="col-sm-3 team-box">

<div class="team-img"> <img src="<cms:show image />" alt="<cms:show k_page_title />"></div>
<ul class="box">
<li>
<h3><a href="#"><cms:show k_page_title /></a></h3>
<span><cms:show designation /></span>
<div class="gap-20"></div>
<p><cms:show text /></p>
</li>
<li>
<div class="tsocial">
<ul>
<cms:if facebook ><li><a href="<cms:show facebook />"><i class="fa fa-facebook"></i></a></li></cms:if>
<cms:if twitter ><li><a href="<cms:show twitter />"><i class="fa fa-twitter"></i></a></li></cms:if>
<cms:if linkedin ><li><a href="<cms:show linkedin />"><i class="fa fa-linkedin"></i></a></li></cms:if>
<cms:if google_plus ><li><a href="<cms:show google_plus />"><i class="fa fa-google-plus"></i></a></li></cms:if>
</ul>
</div>
</li>
</ul>
</div>

<cms:if my_loop_count='4'>
</div>
</cms:if>
</cms:pages>

<cms:if my_loop_count lt '4'>
</div>
</cms:if>
Hi,

I think following is what you are looking for (it lists individual folders with the pages within each folder) -
Code: Select all
<cms:folders masterpage='team.php' orderby='title'>

    <h2><cms:show k_folder_title /></h2>
   
    <cms:pages masterpage='team.php' folder=k_folder_name >
        ..
        <h3><a href="#"><cms:show k_page_title /></a></h3>
        ..
    </cms:pages>
   
</cms:folders>

Does this help?
This worked perfectly. Thanks KK!
3 posts Page 1 of 1
cron