Hey guys,
I'm having a little problem with MIGX and getting the id of the resource where I use MIGX. This is what I'm trying to create:
I have a page with projects where you see a bunch of thumbnails. When you click a thumbnail, a detailed version of the projects slides down at the top of the page. In the detail you can click the image to trigger the colorbox and see different images of the project.
Every project is a different resource within a container resource. Each project-resource has some template variables, one of them is MIGX (for the colorbox).
For Colorbox and other jquery stuff I need the ID of the project resource (so the actual resource-id, not the id of the container). I get these items like this:
<div class="detail-[[+id]] detail" style="display:none;" >
<div class="mosaic-block cover2">
<a href="javascript:void(0)" target="_blank" class="mosaic-overlay mosaic-backdrop"><img src="[[+tv.imagerealisatie:phpthumbof=`w=300&h=204`]]" alt=''/></a>
<a href="[[+tv.imagerealisatie]]" target="_blank" class="group[[+id]]">
<div class="hoverslideshow">
<h4 class="slideshow">Klik om slideshow te bekijken</h4>
</div>
</a>
[[!getImageList? &tvname=`afbeeldingen_realisaties` &tpl=`afbeeldingen_realisaties` &docid=`[[+id]]`]]
</div>
<p class="hide" style="display: none;">Verberg realisatie</p>
<div class="project-text">
<h2>[[+pagetitle]]</h2>
<p>[[+introtext]]</p>
</div>
</div>
where my tpl for the MIGX (afbeeldingen_realisaties) contains this
<a href="[[+thumb_realisaties]]" target="_blank" class="group[[+id]]"></a>
I then output everything on the container page with getResources:
[[getResources? &tpl=`detailsProject` &parents=`4` &hideContainers=`1` &includeTVs=`1` &processTVs=`1` &showhidden=`1`]]
everything gets outputted as wanted except for the
[[+id]] in the MIGX tpl
<a href="[[+thumb_realisaties]]" target="_blank" class="group[[+id]]"></a>
I guess this is because it is printed within the getResources tpl and doesn't know which id he's used in.
Is there a way to get the pageid of the project-resource where the MIGX is used in without using a TV?
Hope I explained it well, if not I'll be happy to answer your questions to clarify my case.
Thanks in advance
Yannick