jetpack

Mozilla Jetpack: multiline notifications?

I just started playing around with Mozilla Jetpack, and I love it so far. I wrote a little code that displays an icon in the statusbar that, when clicked, brings up a notification: var myTitle = 'Hello World!'; var line1 = 'I am the very model of a modern Major-General,'; var line2 = 'I\'ve information vegetable, animal, and mineral,';...

Getting jQuery to work in Jetpack

Hi, I am experimenting with Jetpack and I would like to parse all the years in a given html page and then wrap the year with a link to the Wiki page. I tried the code in jquery and there it works but now I am using it in Jetpack and it gives an error $(doc).replace is not a function. I am definitely new to Jquery / Jetpack so maybe I am ...

How do I style a Jetpack status bar panel correctly?

When I create a status bar panel in Mozilla Jetpack, it looks like a featureless grey box which "interrupts" the status bar, as it lacks the borders/shading/etc. that make it look like a normal status bar panel. How can I get it to look like other status bar panels? ...

Mozilla Jetpack: Why is the title and favicon of the window/tab not updating?

I'm playing around with jetpack to change the title (and ideally the favicon) of certain pages. Firebug is showing that the HTML of the page has been changed correctly but Firefox just won't update the title of the window and/or tab. This has to be possible, somehow, since Twitter Search is doing exactly that. It's updating the title...

Access tab loading image using jetpack

Is it possible to access and trigger the tab loading image within a Firefox tab using jetpack? I want to create a jetpack that will trigger the tab loading image when it is performing a query but i'm not sure if this is even possible. ...

How can I open a browser tab with Jetpack in Thunderbird?

This code will work with Jetpack in Firefox: jetpack.tabs.open("https://www.google.com/calendar"); How can I do the same in Thunderbird? (if I run this code there it gives me a "browserWindow is null" error) ...

Problem with getting the VALUE of a select list using jquery

This is a problem I face while using jQuery within Firefox Jetpack. In my Jetpack code I'm dynamically creating some SELECT boxes with options and their respective values: ... listOfWords[i] = "<select id=clozefox_answer> <option value=wrongAnswer>distractor</option>" listOfWords[i] += "<option value=trueAnswer>" + currentWord + "</opti...

What are Mozilla Labs' Jetpack IO capabilities?

Are you able to access your file-system, using Jetpack, and do operations such as creating or reading files or saving images? ...

How to replicate the dialog functionality of jQuery UI in Jetpack?

I'm trying to get a very basic and simple dialog in my Javascript, actually I'm trying to replicate something very similar to this example from jqueryui website: <script type="text/javascript"> $(function() { $("#dialog").dialog({ bgiframe: true, height: 140, modal: ...

How to Split strings in Mozilla Jetpack

Well , i have tried Split("?") and Split('?') both give the same error ( link.split is not a function) , so i assume that there is a way to be able to split in jetpack but not using this Split ? maybe jQuery ? hope someone can help in this issue. Got it , it is a href Split , so yeah as jordan said , it was not a string . so i used x...

how to loop on hrefs ?

so , what i need is to get some links from the following code. I managed to reach the href of the first one by using var link=doc.querySelector('#courses_menu > ul > li:nth-child(2) a'); Now I need all these href's ! by a loop maybe ? here is the source i need to work on. <ul class="tools-menu-ul"> <li class="tools-menu-back"...

how to add a var to href

well what is needed is something like var link = " http://www.google.com"; < a href= 'link' /> or something like it . so i need to use a var as a href ? anyway to do such thing ? forgot to mention iam using it under mozilla jetpack - html : "" tag it worked with "< a href= ' " + link + " ' /> anyone has a better way ? ...

Why the value inside the loop and using the [i] is undefined ?

using Mozilla jetpack , when i do the following code .. i get that linking is undefined !!! why ? or how to fix it ? var links = doc.querySelectorAll('#courses_menu > ul > li > a'); var linkz=links[1].href.split("?"); var i = 0; for (i=0;i<=4;i++) { var linking= links[i]; } jetpack.notifications.show(" "+ linking); ...

How to get info from another website from my HTML page ?

What is needed is as follows: I have an HTML webpage and I need to access another website and get something from its source code. I want to run something like link = "http://www.google.com"; doc.querySelectorAll('#courses_menu > ul > li > a'); // Apply on the link. to get what I need from the link and use it! However, I am using J...

Why can't I get the icons when I use jQueryUI with Google Ajax API within Jetpack?

I can't get any icons to be shown on a modal dialog box when I try to use jQueryUI via Google Ajax API. The icons do not appear but when I click on the locations where they are supposed to be the relevant functinality works (e.g. I can resize and close the modal dialog box). Here's the problematic screenshot and my code for Jetpack: htt...

finding visited links in a jetpack extension

Hi, Is there way in jetpack(mozilla's extension development framework) , to find the the visited links in a page? BTW: jquery's a:visited works in firebug , but not in jetpack. i'm guessing it's part of jetpack's security. ...

xpcom/jetpack observe all document loads

I write a Mozilla Jetpack based add-on that has to run whenever a document is loaded. For "toplevel documents" this mostly works using this code (OserverService = require('observer-service')): this.endDocumentLoadCallback = function (subject, data) { console.log('loaded: '+subject.location); try { server....

Creating a new Firefox add-on: XUL or Jetpack?

If you were going to start developing a new Firefox add-on today, would you still use XUL/JS or would you start using Jetpack, the new add-on framework? The XUL way of creating add-ons will continue to exist on Firefox 4 but Jetpack is clearly building steam and I imagine it will become the only way of creating add-ons in the future. ...

How to update script developed with Jetpack SDK

I would like to use Firefox standard add-on update to update my script developed with Jetpack SDK, but how? ...

Firefox Jetpack Development Debugging

So, I'm working with some JS in Firefox and also working with the jetpack sdk. I am working in a JS editor, and then I run the sdk through the command line. However, when there is a bug there is no way to debug this because the JS is being run/loaded before the page and the DOM so firebug is to no avail. Can anyone recommend a better t...