title: how to call Javascript method from MVC4 link (error JavaScript runtime error: Object doesn't support this action)
body: <p>I have a javascript code which should be started after clicking on link on view page, but the error is displayed. What is wrong?
  Error is: '
  0x800a01bd - JavaScript runtime error: Object doesn't support this action'</p>
  
  <p>Javascript code:</p>
  
  <pre><code>var MenuController = function () {    
  };
  
  MenuController.prototype.Logout = function () {
  
      $.ajax({
          type: "GET",
          url: '/Account/Logout',
          success: function (response) {
              alert('log out');
              window.close();
          }
      });
  
  };
  </code></pre>
  
  <p>HTML code:</p>
  
  <pre><code>&lt;a onclick="new MenuController.Logout();" alt="Log out"&gt;Log out&lt;/a&gt;
                              &lt;/li&gt;
  ...
   &lt;script src="/js/Controller/MenuController.js" type="text/javascript"&gt;&lt;/script&gt;
  </code></pre>