Location: PHPKode > projects > Open Power Template > tests/Opt/format/decoration_2.txt
Testing the decoration: arrays + objects.

>>>>templates/test.tpl
<opt:section name="foo">
{$foo.item is 'JOE'}
{$foo.item}
</opt:section>

>>>>data.php

$obj1 = new stdClass;
$obj1->item = 'FOO';
$obj2 = new stdClass;
$obj2->item = 'BAR';

$view->foo = array(0 =>
	$obj1, $obj2
);
$view->setFormat('foo', 'Array/Objective');

>>>>expected.txt
OUTPUT

>>>>result.txt
JOE
JOE
Return current item: Open Power Template