Title: Passing a hash as reference

I think it's a silly question but I don't know how to fix it.

In the .pl program I have a hash table of hash tables like:

my %hash = {
        id => {
                        class => '1030',
                        instance => '1.0.0987',
                   },
        attrs => {
                                label => 'network',
                                value => '20010',
                       
                       },
        };

I'd like to use this hash in the template file. I tried:

my $vars = {
                hash_table => %hash,
                 };

But in the template I can't get for example:

[% hash_table.id.class %]

Thanks in advance

Danilo.

Reply via email to