Javascript/Jquery beginner question
<p>I am learning some jQuery basics with this great book: <a href="http://jqfundamentals.com/book/" rel="nofollow">http://jqfundamentals.com/book/</a></p>

<p>There is an example that doesn't return the right result.</p>

<p>Here is the code:</p>

<pre><code>  var myName = 'the global object',

      sayHello = function () {
          console.log('Hi! My name is ' + this.myName);
      },

      myObject = {
          myName : 'Rebecca'
      };

  var myObjectHello = sayHello.bind(myObject);

  sayHello();       // logs 'Hi! My name is the global object'
  myObjectHello();  // logs 'Hi! My name is Rebecca'
</code></pre>

<p>The log returns <code>undefined</code> instead of <code>the global object</code> for <code>sayHello();</code> and I'd like to know why...</p>
