Forum
Nested perch:content tag does not work.
I tried implementing nested perch:content, but that does not work at all for me.
Find my code below:
PerchSystem::unset_var('default_site');
PerchSystem::set_var('default_site', 'My Site');
Passing the above mentioned variable to perch template, code as below:
<perch:content id="site" type="text" label="Site" default="<perch:content id="default_site" type="hidden" />" />
How can go ahead with this piece of code?
No, that won't work - you can't do that.
:-( that's sad.
If you set a var with the same ID it will pre-fill. But you can't just jam tags inside each other and hope for the best.