hi guys thanks for the help. I looked into the parsechunk function, I don’t think I need that
I’m not sure how it is supposed to work but it works like this: the getChunk function gets the chunk from the database $modx->getChunk(..), and eForm doesn’t pay attention to eventual nested chunks. When I echo it on screen, the ’{{chunkname}}’ is still there.
So.. I did fix it like this ($tpl is the initial chunk):
preg_match_all("#{{(.*?)}}#",$tpl,$matches);
foreach($matches[1] as $name => $value)
{
$tpl = str_replace("{{".$value."}}", $modx->getChunk($value), $tpl);
}
which does works perfectly, but I can imagine there is a better way. Is the getChunk function supposed to return the complete parsed chunk or just as it sits in the database?
thanks again