title: Is it possible to use workers in a Greasemonkey script?
body: <p>I would like to use the Web Worker facility introduced in Firefox 3.5 to enhance a Greasemonkey script I'm working on.</p>
  
  <p>Is this even possible?</p>
  
  <p>I've done some experimentation, but I can't get past the issue of loading a worker script from an arbitrary domain.</p>
  
  <p>For example, this does not work:</p>
  
  <pre><code>var myWorker = new Worker("http://dl.getdropbox.com/u/93604/js/worker.js");
  </code></pre>
  
  <p>This code generates an error message in my Firebug console:</p>
  
  <blockquote>
    <p>Failed to load script:
    <a href="http://dl.getdropbox.com/u/93604/js/worker.js" rel="noreferrer">http://dl.getdropbox.com/u/93604/js/worker.js</a>
    (nsresult = 0x805303f4)</p>
  </blockquote>
  
  <p>Apparently there's a limitation that does not allow you to start a worker from a URL that's not relative to the base URL of the calling script. You can load a worker script at a relative URL like this just fine:</p>
  
  <pre><code>var myWorker = new Worker("worker.js");
  </code></pre>
  
  <p>But there's no way for me to get the worker script on the user's filesystem so that it could be at a path relative to the calling script.</p>
  
  <p>Am I screwed here? Should I give up on trying to use workers within my Greasemonkey script?</p>