Skip to content

Hacking Firefox 1.5 extensions for 2.0

One of the bad things about upgrading to a new Firefox major version is that inevitably, some of your favourite extensions won’t be modified to work with the new version. And with Firefox extensions being so awesome (and arguably crucial to Firefox’s success)…

But, thankfully, it’s not too difficult to hack the extension files to make your extensions work with the new version.

Before I begin – this process could make your extension (and maybe your Firefox profile too) not work – so do it at your own risk! Having said that, starting Firefox in Safe Mode and uninstalling the culprit extension usually fixes any extension issues that may arise.

I’ll be using BoxCheck for this tutorial.

Downloading your extension without installing it

First of all, we need to get a copy of the .xpi extension file without installing it. You could use a browser other than Firefox, but the easiest way is to just right-click the extension download link and choose Save Target As…. Save the file anywhere.

Unzip and go!

Now you have a .xpi file. Well, it’s worth explaining at this point that these .xpi files are actually just standard Zip archives with special installation files in them that Firefox uses to install them (the extension code is generally just JavaScript and XUL).

So, with that in mind, just rename the file’s extension from .xpi to .zip and unzip it using your favourite program (Windows us
a new folder (not the one you’re currently in, you’ll get confused).

Extracting filesExtracting files Hosted on Zooomr

Enter this new folder and open the install.rdf file in your favourite text editor.

install.rdf for BoxCheckinstall.rdf for BoxCheck Hosted on Zooomr

Hacking install.rdf

Find the snippet of code including these lines.

[xml]em:minVersion=”1.0″
em:maxVersion=”1.5.0.*”[/xml]

What these lines do is instruct Firefox what the minimum and maximum versions of Firefox this extension is guaranteed to work with. Change the maxVersion line to read 2.*. This will make the extension work with any Firefox in the 2.x series.

[xml]em:minVersion=”1.0″
em:maxVersion=”2.*”[/xml]

Zip it back up

Save and close the file. Now, we need to zip the archive back up. Make a Zip archive of the contents of the folder. It is important that you don’t zip up the folder you extracted to, only the contents of the folder you extracted to.

Now, rename your new .zip file to something useful with the .xpi extension, like boxcheck_ff2.xpi.

Install time!

Launch Firefox if it’s not already open, and open the Tools > Add-ons window. Go to the Extensions tab. Drag the new .xpi file from your file manager into the Add-ons window.

Add-ons windowAdd-ons window Hosted on Zooomr

A standard installation dialogue should appear. Install your extension, restart Firefox and enjoy!

One last reminder…

Just to reiterate, hacking extensions in this way is unsupported and isn’t a particularly good idea. Always check for updates to your Add-ons first to see if the developers have released a Firefox 2.0-compatible version. Failing that, you can use this method, but again, at your own risk.

Don’t come to me if it eats your dog, cat, other pets, first born child and Firefox profile.

And sorry for the recent lack of posts, I’ve been not too well recently. I’m much better now though, and you can expect normal service to be resumed!

Like this post?

If you would like to support the time and effort I have put into my tutorials and writing, please consider making a donation.

2 Comments

  1. Shadoefax wrote:

    If you don’t want to re-download all your extensions, you could use FEBE to extract them from your current profile into installable .xpi files.

    Tuesday, December 5, 2006 at 04:52 | Permalink |
  2. hari wrote:

    vvvvv good

    Saturday, March 15, 2008 at 06:44 | Permalink |

Post a Comment

On some sites, you must be logged in to post a comment. This is not the case on this site.
Your email address is not made public or shared. Required fields are marked with *.
*
*
*

Posting a comment signifies you accept the privacy policy.
Please note — your comment will not appear straight away, as all comments are held for approval.