Object has a property that is a function, but console says it has no such method
<p>I'm trying to use a jQuery plugin called <a href="http://jpanelmenu.com/#api-on" rel="nofollow">jPanelMenu</a>. To use it, you create a special object:</p>

<pre><code>var jpm = jQuery.jPanelMenu();
</code></pre>

<p>and call a method of that object:</p>

<pre><code>jpm.on();
</code></pre>

<p>So when I create the object, I can type its name and see a list of its properties, which does indeed include an 'on' property.</p>

<p>I can type <code>jpm.on</code> and see that this property looks like a function. </p>

<p>I can do <code>typeof jpm.on</code> and it returns <code>"function"</code>.</p>

<p>But when I call <code>jpm.on();</code>, I get </p>

<pre><code>TypeError: Object #&lt;Object&gt; has no method 'on'
</code></pre>

<p>Here's a screenshot of me doing all the above in the console:</p>

<p><img src="http://i.stack.imgur.com/4r5f9.png" alt="Screenshot of the above in Chrome's JavaScript console."></p>

<p>I'm not terribly keen with JavaScript, so I assume this is some gap in my basic conceptual knowledge. What is really going on here?</p>
