I just made a FF addon and made a simple website. I'd like when a visitor clicks the "download" button the addon to install, instead of getting downloaded. It works locally, but not when I upload the site. I checked the mozilla repository, they just link to the xpi file as well.
What am I doing wrong?
The problem is that you haven't registered the XPI MIME type for your website. You can do this by adding the following rule to your site's .htaccess
file (assuming your site uses an Apache server):
AddType application/x-xpinstall .xpi
This should result in what you want (a user clicks the link and is prompted to install the XPI file).
Fore More Reference https://developer.mozilla.org/en-US/Add-ons/Extension_Packaging#Making_an_extension_XPI
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With