[Templates] differentiating hash entries / methods with same name

Josh Rosenbaum josh@infogears.com
Tue, 07 Nov 2006 14:52:19 -0700


Dami Laurent (PJ) wrote:
> Hi all,
> 
> Suppose an object $obj has both a hash entry $obj->{foo} and a method 
> $obj->foo().
> 
> If I pass this object to a template,  [% obj.foo %] performs a method call.
> 
>  Is there a way to access the hash entry instead?
> 
> Thanks in advance, L. Dami
> 

Does obj.item('foo') work?

-- Josh