How do I access the value of this JavaScript object?
<p>What type of object is <code>container</code>?</p>

<pre><code>var pname = "apples";
var extVal = "oranges";

var container = {};
container =
{
    presName: pname,
    presVal: pname
};
</code></pre>

<p>I want to compare the value of <code>presVal</code> (from inside <code>container</code>) to the value of <code>extVal</code>.</p>

<p>But I'm not sure how to access <code>presVal</code> to make this comparison.</p>
