Search Support

Avoid support scams. We will never ask you to call or text a phone number or share personal information. Please report suspicious activity using the “Report Abuse” option.

Learn More

Lolu chungechunge lwabekwa kunqolobane. Uyacelwa ubuze umbuzo omusha uma udinga usizo.

I'm an Add-on developer, I want to pack extension which has jquery libraries?

  • 2 uphendule
  • 2 zinale nkinga
  • 62 views
  • Igcine ukuphendulwa ngu ahmedsamir

more options

I'm an Add-on developer, I want to pack my extension which has Jquery libraries and get its skeleton folder?

I'm an Add-on developer, I want to pack my extension which has Jquery libraries and get its skeleton folder?

All Replies (2)

more options

I am also addon developer. I use it like this :-

I use the following example.xul:

<overlay id="example" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> <head></head> <script type="application/x-javascript" src="jquery.js"></script> <script type="application/x-javascript" src="example.js"></script> </overlay>



And here is an example.js

(function() {

   jQuery.noConflict();
   $ = function(selector,context) { 
       return new jQuery.fn.init(selector,context||example.doc); 
   };
   $.fn = $.prototype = jQuery.fn;
   example = new function(){};
   example.log = function() { 
       Firebug.Console.logFormatted(arguments,null,"log"); 
   };
   example.run = function(doc,aEvent) {
       // Check for website
       if (!doc.location.href.match(/^http:\/\/(.*\.)?stackoverflow\.com(\/.*)?$/i))  
           return;
       // Check if already loaded
       if (doc.getElementById("plugin-example")) return;
       // Setup
       this.win = aEvent.target.defaultView.wrappedJSObject;
       this.doc = doc;
       // Hello World
this.main = main = $('
').appendTo(doc.body).html('Example Loaded!');
       main.css({ 
           background:'#FFF',color:'#000',position:'absolute',top:0,left:0,padding:8
       });
       main.html(main.html() + ' - jQuery ' + $.fn.jquery + '');
   };
   // Bind Plugin
   var delay = function(aEvent) { 
       var doc = aEvent.originalTarget; setTimeout(function() { 
           example.run(doc,aEvent); 
       }, 1); 
    };
   var load = function() { 
       gBrowser.addEventListener("DOMContentLoaded", delay, true); 
   };
   window.addEventListener("pageshow", load, false);

})();

more options

we have this problem on firefox add-on validation: "Your add-on includes an JavaScript library file (jQueryUI) that doesn't match our checksums for known release versions. We require all add-ons to use unmodified release versions, obtained directly from the developer's website. You can find a list of the library versions we support here: http://mzl.la/amo-libs"

we downloaded Jqueryui from http://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.js and then we got its hash from https://github.com/mozilla/amo-validator/blob/master/validator/testcases/hashes.txt it was "324b0783a50c21c9b2a105b39b7cd1767e8d44f288f08be5f6e2267d5ad83920" how can we add it to harness-options.json ?