如何通过窗口小部件代码使用网站的jQuery

| 我有一个添加到随机网站的小部件。 每当这些站点使用jQuery时,我都希望我的代码使用它,而不要再次上传jQuery。 如何一次性设置,我对jQuery的函数调用会调用站点的jQuery,可能使用不同的jQuery前缀($)?     
已邀请:
使用匿名函数测试jQuery对象的存在。如果未定义,请将其添加到DOM中,然后稍等片刻,然后重试:
void(function()
  {
  if (/function/.test(this[\"jQuery\"]) == false)
    {
    var anon = arguments.callee;
    var jqs = document.createElement(\"script\");
    jqs.src = \"http://code.jquery.com/jquery-latest.js\";
    document.getElementsByTagName(\"body\")[0].appendChild(jqs);

    window.setTimeout(function () {anon();}, 500);
    }
    else
      {
      $(document).ready(function(){document.title = \"jQuery\"});
      }
  }
());
    

要回复问题请先登录注册