JavaScript object, call on page
<p>I have one javascript file that houses all the functions for my website, stored it a large object, like this:</p>

<pre><code>var Example = {

init : function(){
    alert('init');
},

page_one : function(){
    alert('this is page 1');
},

page_two : function(){
    alert('this is page 2');
}
</code></pre>

<p>}</p>

<p>Now I like to open a simple script tag on the different pages, and on page1 do <code>Example.page_one();</code> and on page2 do <code>Example.page_two();</code></p>

<p>But this doesn't work. When I call those in the same file as where die Example object is made, then it works, but not if I include that file in a page, and call it from there. </p>

<p>The Example object does show up in the <code>window</code> object</p>

<p>Can someone help me?</p>
