title: chrome.extension.onMessage.addListener Cannot read property 'onMessage' of undefined
body: <p>In the <code>background.html</code>:</p>
  
  <pre><code>chrome.tabs.query({active:true, currentWindow:true},function(tabs){
    chrome.tabs.sendMessage(tabs[0].id,"target.js");
  });
  </code></pre>
  
  <p>In the <code>content.js</code>:</p>
  
  <pre><code>chrome.extension.onMessage.addListener(function(msg,sender,sendResponse){
    if (msg == "target.js"){
      extensionID = sender.id;
    }
  });
  </code></pre>
  
  <p>However, it doesn't work;</p>
  
  <pre><code>Uncaught TypeError: Cannot read property 'onMessage' of undefined 
  </code></pre>
  
  <p>How to make it right?</p>