If you want to use an arrayfields value as attribute for a function, you can't use:
{func var="test $foo[bar] test"} <-- sees $foo[bar]
like described in the
manual. You have to use this instead:
{func var="test `$foo.bar` test"} <-- sees $foo[bar]