title: Using jinja2 templates to display json
body: <p>I have a flask web app set up using jinga2 templates and Json. I'm trying to display the data stored in the json file in my html template. I ideally would like it to display and looks like a list in the html. The page should display the json in a recipe format e.g step my step but I can't seem to get it to work.  </p>
  
  <p>I have included my python file, json and html template to help with reproducing the issue. </p>
  
  <p>This is my python file:</p>
  
  <pre><code>@app.route('/recipes/pumpkin_pie/')
  @app.route('/recipes/halloween/pumpkin_pie/')
  def pumpkin_pie():
    recipes = []
    with open('recipes.json', 'r') as f:
       recipes = json.load(f)
       f.close()
    print recipes
  
    p = {}
    for item in recipes:
       if item['name'] == "pumpkin pie":
         print item
         p = item
         print p
  
    return render_template('pumpkin_pie.html', pumpkin=p)
  </code></pre>
  
  <p>This is my html tempate file:</p>
  
  <pre><code>&lt;div class="container"&gt;
  &lt;div class="ingredients"&gt;
      &lt;p&gt;{{ pumpkin.ingredients }}&lt;/p&gt;
  &lt;/div&gt;
  &lt;div class="method"&gt;
      &lt;ul&gt;
      {% for result in pumpkin %}
          {% for methods in result %}
              &lt;li&gt;{{pumpkin.methods }}&lt;/li&gt;
          {% endfor %}
      {% endfor %}
      &lt;/ul&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p></p>
  
  <p>This is my json file:</p>
  
  <pre><code>{
  "name": "pumpkin pie",
  "ingredients": [" large eggs plus 1 yolk", "1 tsp ground cinnamon"],
  "methods": {
      "1": "Pre-heat the oven to 200C/400F/Gas 6",
      "2": "If using a shop bought sweet crust pastry case, use one that is 23cm/9in diameter and 4cm/1.5in deep. If using your own pastry, roll it out and use it to line a 23cm/9in pie plate (not loose bottomed). Bake the pastry case blind for 20 minutes."
  } }
  </code></pre>