title: How to print a json in Smarty
body: <p>Am getting a json from an api, how to print the json using Smarty. </p>
  
  <p>Json format </p>
  
  <pre><code>[
      {
          "first_name": "jinu",
          "last_name": "mk",
          "loginid": "jinu@amt.in",
          "timezone": "5.5",
          "team_id": "c964ef415f157ddd99173f5b481ee1e3",
          "user_type": 1,
          "last_login_date": null
      },
      {
          "first_name": "avatar second",
          "last_name": "test",
          "loginid": "avatar2@gmail.com",
          "timezone": "5.5",
          "team_id": "ec40f5feda8643135bc20be44f897b03",
          "user_type": "3",
          "last_login_date": null
      },
      {
          "first_name": "avatar testing admin",
          "last_name": "amt 1",
          "loginid": "avatar@amt.in",
          "timezone": "5.5",
          "team_id": "ec40f5feda8643135bc20be44f897b03",
          "user_type": 1,
          "last_login_date": null
      }
  ]
  </code></pre>
  
  <p>I have tired the following foreach but its not printing anything.</p>
  
  <pre><code>{foreach from=$games item=foo}
       &lt;li&gt;{$foo.first_name}&lt;/li&gt;
  {/foreach}
  </code></pre>
  
  <p>Please help me to solve this issue. Thanks </p>