I am trying to run this code in my HTML:
<tbody>
{% for name, npcBuy in zip(farmingMerchantName, farmingMerchantPrices) %}
<tr>
<td>{{ name }}</td>
<td>temp</td>
<td>{{ npcBuy }}</td>
<td>temp</td>
</tr>
{% endfor%}
</tbody>
But I get the error: jinja2.exceptions.UndefinedError: 'zip' is undefined
I have tried these following things in Python as well:
import jinja2
app.jinja_env.globals.update(zip=zip)
And this:
Import jinja2
env = jinja2.Environment()
env.globals.update(zip=zip)
(not at the same time)
from the first one, I get the error "Method 'jinja_env' has no 'globals' member.
And from the second one, well I get the same error (jinja2.exceptions.UndefinedError: 'zip' is undefined)
I have checked this thread out, but it did not help.
Thanks