firefox-addon

How to smoothly open panes across tabs in Firefox extension?

Our Firefox extension displays the top 25 Bing results in a side pane whenever someone searches from Google. The results are scrubbed for duplicates. The side pane is closed by default. Only when someone views a Google results page does the side pane open. The side pane automatically closes again when someone opens a non-Google page....

Firefox extension development : Get URL of new tab

Hi All, Can anybody tell me how to get the URl of the next tab on firefox ? I am using this now : //The browser object points to the new tab which I capture using the //'TabOpen' Event var browser = gBrowser.getBrowserForTab(event.target); //From where can I get the URL of this new tab ? Also, how to I get //the Title of this new T...

Redirecting Request (nsiHttpChannel?) in Firefox Extensions

I've been trying at this for a long time now, and no good results. var myObserver = { observe: function(subject, topic, data) { if (topic == "http-on-examine-response") { // implement later } else if(topic == "http-on-modify-request") { // implement later } }, QueryInterface : function (id) { if (id.equ...

Firefox Extension : onProgressChange called multiple times

Hi All, I am trying to capture a page load event while developing a extension for firefox. I am using ProgressListeners for this. I cannot use the onLocation change event because it fires an event every time the user switches the tab. I just want to log every new page he has visited. OnProgressChange works for me, but this is fired m...

How to modify web page elements loaded in a browser

I want to associate some actions with keys (of a keyboard) and then modify the contents of a webpage loaded in the browser. For example, I'll write a firefox plugin and that would be listening to some keyboard events. Based on a key press (or something like that) I want to modify the html code of the page. For example, I would like to ch...

Maximum length of a String Preference in Firefox ?

I would like to know what is the maximum length of a String when saving in the classic preferences System: var prefs = Components.classes["@mozilla.org/preferences-service;1"] .getService(Components.interfaces.nsIPrefBranch); prefs.setCharPref("com.exemple.namespace.preference", potentiallyLongString); Couldn't find it...

In regards to stopping a nsIRequest before completion and determining when a nsIRequest is complete (firefox extension)

Thanks to everyone in advance! I am using a xul:browser and attaching a nsIWebProgressListener to it. I am trying to accomplish two things: 1. Determine when a request is complete (when a document is completely load with all css/js/imgs). 2. Stop a request from completing, specifically URLs with files that issue the download prompt. In...

change global function scope in javascript

Is the following possible: var someObject = {someProperty : "someValue"}; var someFunction = function() { someProperty = "anotherValue"; }; // what do I do here, in order to use // someFunction to change someObject, // without altering either of those things? // directly accessing "someObject" in someFunction // is not an option. e.g...

.Net Add-ons for Firefox ?

Can we write some add-ons for Firefox with .Net Framework (C# or VB) ? ...

Is the score/feedback that SenSEO FF plugin provides of any real world value?

Greetings! I started doing some seo optimization on one of my projects and decided to give the SenSEO plugin shot. But I'm wondering what the real world value of its feedback is. If your project scores A or B with the plugin, does it show up at the top of the searches? Thanks ...

Firefox extension development: How open file dialog on any link

I want to create extension, that's allow open save dialog in ff on any link (not "save as" dialog - dialog with choice of download method (usually it apperas, when click on file)). Any body knowns - it's possible? and how? ( may be source draft, link, any information ) P.S. sorry for my English ...

Setting a preference at startup in firefox

Thanks to everyone in advance - I need to load a preference before any windows are loaded at startup. Below is some /component code I have been working with. The SetPreference method seems to fail when it is called (nothing executes afterwords either) - I am assuming because the resources that it needs are not available at the time of e...

How do I determine if my addon is running in firefox or in fennec?

I am making an addon for both firefox and fennec and I want to know if it is running on fennec or not. ...

Firefox extension - password strenght measure

Hi! I am developing an extension to firefox that indicates to the user what is the strenght of his passwords. For instance, the user inserts a password on a password field and the extension will measure password strenght immediately. What shoul I overlay, ths browser.xul? What events should I use? Thanks. ...

Manipulate Html from Firefox Extension

I am creating a Firefox extension that is somewhat similar to Firebug. There is a panel (or vbox) at the bottom of the browser that allows users to specify colors to certain Html elements. When they click the OK button, I would like these colors to get updated on the current web page. I have my JavaScript working when I click the butto...

Set Image Src to Local File

I am writing a Firefox extension and would like the users to be able to change an image on a web page with a local image. Is it possible, using JavaScript, to change the image source with an image that is saved on the user's local machine? Let me know if you need more information. Thanks ...

Getting raw response data from with in a nsIWebProgressListener interface

Thanks to everyone in advance! I have attached a nsIWebProgressListener to a xul:browser and was wondering if it was possible to get the raw response data back? Getting the headers and body would be nice, but I am really just looking for the body. I looked into nsIRequest, which gets passed into all of the methods (onStateChange,onPr...

Using NPRuntime plugin in Firefox extension.

I have successfully run NPRuntime plugin on webpage by copying it to firefox plugin directory. I want to create a firefox extension using it, so I created small extension that displays a textbox and a button on status bar, button click calls a javascript function which takes value from textbox and passes as a argument to the function in ...

How to access window object from XUL?

I'm trying to set an onLoad event to the current web page from a firefox extension. I'm using the gBrowser object but I'm not sure if this is the best way. I would like to set an onLoad event to the web page window to execute some actions of the plugin as soon as the page is loaded. Thanks in advance. ...

Objects in JavaScript defined and undefined at the same time (in a FireFox extension)

I am chasing down a bug in a FireFox extension. I've finally managed to see it for myself (I've only had reports before) and I can't understand how what I saw is possible. One error message from my extension in the Error Console is "gBrowser is not defined". This by itself would be surprising enough, since the overlay is over browser.xu...