Hi All,
I am trying to fit couch to what was a wordpress theme, now I am using the documented gallery method but need to adjust it so that the istope filter menu is the "Parent" categories - got this working fine with depth="1" - but the loop to load the child categories I am stuck with, this loop also needs to be able to pull the parent folder id as a class hook to filer by.
I believe it's something in this section that needs modifying but not sure how to approach it:
My full "our-work" template is:
I am trying to fit couch to what was a wordpress theme, now I am using the documented gallery method but need to adjust it so that the istope filter menu is the "Parent" categories - got this working fine with depth="1" - but the loop to load the child categories I am stuck with, this loop also needs to be able to pull the parent folder id as a class hook to filer by.
I believe it's something in this section that needs modifying but not sure how to approach it:
- Code: Select all
<cms:set my_page="<cms:gpc 'pg' method='get' />" />
<cms:if my_page lt '2' >
<cms:folders childof=k_folder_name hierarchical='1' depth='2'>
<cms:set my_folder_image="" />
<cms:if k_folder_image>
<cms:set my_folder_image="<cms:thumbnail k_folder_image width='500' height='300' />" />
<cms:else />
<cms:pages folder=k_folder_name include_subfolders='0' limit='1'>
<cms:set my_folder_image=my_thumb_2 scope='parent' />
</cms:pages>
</cms:if>
<cms:if my_folder_image=''><cms:set my_folder_image="<cms:show k_site_link />assets/img/folder-empty.png" /></cms:if>
My full "our-work" template is:
- Code: Select all
<div id="main" class="clearfix">
<div id="container" class="clearfix">
<!--BEGIN #content -->
<div id="content">
<!-- BEGIN #archive-title -->
<div id="archive-title">
<div class="inner term-31 term-28 term-37 term-38 term-6 term-29 term-26 ">
<h1 id="page-title">
Our Work <span class="icon"><img src="http://demo2.designerthemes.com/adapt/wp-content/themes/adapt/images/icon-ribbon.png" alt="" /></span>
</h1>
<ul id="filter" class="clearfix">
<li class="active"><a href="#" data-filter="*">All</a> (11)</li>
<cms:folders masterpage='our-work.php' hierarchical='1' depth='1'>
<li class="segment-30"><a href="#" data-filter=".f<cms:show k_parent_folder_id />" title="View all <cms:show k_folder_title />"><cms:show k_folder_title /></a> <cms:show k_folder_totalchildren />
</cms:folders>
</ul>
</div>
</div>
<!-- END #archive-title -->
<!--BEGIN #masonry -->
<div id="masonry">
<cms:set my_page="<cms:gpc 'pg' method='get' />" />
<cms:if my_page lt '2' >
<cms:folders childof=k_folder_name hierarchical='1' depth='2'>
<cms:set my_folder_image="" />
<cms:if k_folder_image>
<cms:set my_folder_image="<cms:thumbnail k_folder_image width='500' height='300' />" />
<cms:else />
<cms:pages folder=k_folder_name include_subfolders='0' limit='1'>
<cms:set my_folder_image=my_thumb_2 scope='parent' />
</cms:pages>
</cms:if>
<cms:if my_folder_image=''><cms:set my_folder_image="<cms:show k_site_link />assets/img/folder-empty.png" /></cms:if>
<div class="item normal isotope-item">
<!--BEGIN .hentry -->
<div id="id<cms:show k_folder_id />" class=".f<cms:show k_parent_folder_id /> showcase type-showcase status-publish format-image hentry">
<!--BEGIN .featured-image -->
<div class="featured-image">
<div class="da-animate da-slideFromLeft" style="display: block;">
<span class="da-wrap">
<span class="title"><cms:show k_folder_title /></span>
<a href="<cms:show k_folder_link />" class="colorbox-image cboxElement" data-gallery="group-1227">View Work</a>
</span>
</div>
<a href="http://demo2.designerthemes.com/adapt/showcase/bamboo-holder/"><img width="300" height="177" alt="" src="<cms:thumbnail k_folder_image width='500' height='300' />"></a>
<!--END .featured-image -->
</div>
<h2 class="post-title"><a href="<cms:show k_folder_link />"><cms:show k_folder_title /></a></h2>
<!--BEGIN .post-content -->
<div class="post-content">
<span class="icon"></span>
<p><cms:show k_folder_desc /></p>
<!--END .post-content -->
</div>
<!--END .hentry-->
</div>
<!--END .item -->
</div>
</cms:folders>
</cms:if>
<!--END #masonry -->
</div>
<div id="masonry-new"></div>
<!--BEGIN .post-navigation -->
<div class="post-navigation clearfix">
<!--END .post-navigation -->
</div>
</div><!-- #content -->
<!--END #content -->
</div>
<!--END #main -->
</div>
<!--END #page -->
</div>