Location: PHPKode > projects > Open Power Template > tests/Opt/instruction/root_5.txt
Testing the "opt:root" dynamic attribute.

>>>>templates/included.tpl
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<opt:root>
	<opt:snippet name="foo">
		<p>foo</p>
	</opt:snippet>
</opt:root>

>>>>templates/test.tpl
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<opt:root include="default.tpl" dynamic="yes">
<opt:insert snippet="foo" />
</opt:root>

>>>>data.php
$view->inherit('included.tpl');

>>>>expected.txt
OUTPUT

>>>>result.txt
<p>foo</p>
Return current item: Open Power Template