How to iterate through keys and values of JSON Object in jsp
<p>I'm passing in a <code>JSONObject</code> into my jsp file. I want to be able to display dynamically all the keys and its associated values in the jsp file. I know how to do this in Java, as I can do this:    </p>

<pre><code>Iterator&lt;?&gt; keys = jsonObject.keys();
    while(keys.hasNext()) {
        String key = (String)keys.next();
        String value = jsonObject.get(key).toString();
        System.out.println(key);
        System.out.println(value);
    }
</code></pre>

<p>I am confused as to how to do this in my jsp file. Any help on this issue would be greatly appreciated! </p>