Getting id of current edited resource in manager is that possible, I have some TV that get all id from resources like this
@SELECT pagetitle, id FROM modx_site_content WHERE parent=7
The only problem i dont need to be hardcoded 7, i need there to be id of current edited resource in manager?
Like this does not work
@SELECT pagetitle, id FROM modx_site_content WHERE parent=[[*id]]
<a href="www.play2web.com" title="izrada web sajtova">Izrada web sajtova</a>
I have tried like this
<?php
$children = $modx->resource->getMany('Children');
$output = '';
$list = array();
foreach($children as $child)
{
//check if correct template
if($child->get('published')&&$child->get('template')==21)
{
$list[] = $child->get('pagetitle').'=='.$child->get('id');
}
}
$output .= implode('||',$list);
return $output;
But the problem is that only return first ID in TV on frontend returns full value like this
Brzi recepti==14||Predjela==12
<a href="www.play2web.com" title="izrada web sajtova">Izrada web sajtova</a>
I have tried but i only got 14, and first empty
<a href="www.play2web.com" title="izrada web sajtova">Izrada web sajtova</a>