Source:,1217,a=209836,00.asp Make Your Own Firefox Extensions ARTICLE DATE: 06.20.07 By David A. Karp Among the things that make Firefox such a popular alternative to Internet Explorer are extensions—free add-ons that can alter appearance, add features, even change how Web pages are rendered. Most Firefox users have clicked through Tools | Add-ons | Get Extensions (or visited to download some from the main repository. But why not make your own? Fortunately, it's not hard. A typical Firefox extension is nothing more than an XUL (XML User-interface Language) file you can edit with Notepad. In contrast, IE extensions must be compiled into DLLs and then installed into the operating system. The easiest way to get started is to dissect someone else's extension, such as the example at Right-click the Install link and select Save Link As to copy the XPI file to your hard drive. The XPI installer is really just a ZIP file, so change the extension to .zip and then open it. Inside, you'll find three files: install.rdf (the install script for Firefox), install.js (the install script for SeaMonkey and other Mozilla derivatives), and a JAR file containing the extension itself. The JAR file is also a ZIP file; rename it with .zip and open it to edit the goodies inside—start with the steps below, and also check out for in-depth XUL tutorials, including instructions for making menu bars, buttons, and more. When you're done, repackage the XPI, leaving the directory structure intact, and you're done! — next: Step by Step — David A. Karp, compulsive tinkerer and author of Windows Vista Annoyances 1 Customize the Interface Almost all of Firefox's interface is customizable, but for starters, here's a simple context-menu add-on that looks up selected text on Wikipedia. Edit the XUL file to change the appearance of your extension: Menu text goes in the label attribute; the accesskey is the keyboard shortcut, which will be underlined in the menu; insertafter indicates position in the context menu; the name of your JavaScript function goes in the oncommand attribute; and the filename of your JS file goes in the