Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8800809
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T00:41:16+00:00 2026-06-14T00:41:16+00:00

I wrote a Firefox extension (MyPlugin) that adds some features to another Firefox extension

  • 0

I wrote a Firefox extension (MyPlugin) that adds some features to another Firefox extension (MainExtension). I want to put it the Mozilla Add-ons page, but I’d to just check first about the best way to structure such an extension.

Currently, I overlay MainExtension’s xul with MyPlugin’s xul in chrome.manifest. In MyPlugin’s xul, a tag calls a .js file which defines MainExtension.MyPlugin and all of its methods which can be called by elements of the overlay.

Is that setup okay on its own? When I first tried to upload the plugin to the Mozilla Add-ons page, I discovered that the “requires” element of install.rdf is no longer supported. I had been thinking that that would take care of checking that MainExtension is actually installed. Should I put in any error checking in my plugin to make sure that MainExtension is installed? I think that right now the overlay line in chrome.manifest will just fail if MainExtension is not installed and then nothing else will happen, which seems fine. Functionally, I don’t plan on having the plugin installed without the main extension, so this should not be an issue, but since I want to post the extension where other people can download it I want to make sure I am not creating any problems for them (and I’m not that familiar with Firefox extension structure — mostly I put mine together by looking at other published extensions).

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T00:41:17+00:00Added an answer on June 14, 2026 at 12:41 am

    So I worked some more on my extension, read more documentation online, and consulted some with more experienced developers, and the solution that I have come to for now is to use modules to define some of the basic internal parts of my extension. I create a MyPlugin object in the module that is then universal for Firefox by using a module. Then with the script that is called by the overlay of MainExtension’s xul I create another chrome object (called eg MyPluginChrome) that contains just the functions related to interacting with MainExtension’s XUL elements. When asking the question, I though it was necessary to define an XPCOM component in order to make my plugin stand alone and that seemed like overkill for my simple plugin to an existing extension, but using modules makes making the plugin stand alone not much different from the way I had been doing things.

    For learning how to do what I described above, I used the JavaScript Object Management page from the XUL School tutorial at the Mozilla Developer Network site. This tutorial is a little bit quirky (because it was adapted from another source) but very helpful. It is separate from the Building an Extension page also at MDN. Several other older web pages have higher hits on Google, but I found the XUL School tutorial to be the most informative and useful.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I wrote firefox extension and want to be able to install it to firefox
I'm trying to write a Firefox extension that adds elements to the loaded page.
I wrote a process explorer using C with GUI interface. I want to add
I am writing a Firefox extension that needs to write and submit a form
I want to write plugin for GNOME Do , that will work with Firefox
I want to write a simple firefox extension. How can I get a reference
Im currently making a firefox extension that will let you choose what tabs you
Hi: I'm writing a firefox extension (my first) that among other things, gets an
my name is Fernando and I want to write an extension for Firefox which
I'm writing a Firefox extension (add-on) to allow users to annotate any page with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.