Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Hi Monks!!
I am trying to pass a dynamic value to print a value out of an array using Mojo::Template, getting syntax errors, is there a way to do that?
The code works if its like this:
I'd like to pass the index number dynamic using the example below:<% $local->{ place }[ 0 ]{ street } %>
Code snipped from the .ep template file:
<%= $number %>, can be 0,1,2,3...<p> Location: <br/> <% $local->{ place }[ %> <%= $number %> <% ]{ street } %> </p>
Back to
Seekers of Perl Wisdom