Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to write a C++ FireFox 3 plugin (not extension) on Windows?

Could someone write-up a step by step guide to developing a C++ based plugin for FireFox on Windows?

The links and examples on http://www.mozilla.org/projects/plugins/ are all old and inaccurate - the "NEW" link was added to the page in 2004.

The example could be anything, but I was thinking a plugin that lets JavaScript set the name and then displays "Hello {Name}". To show 2-way communication, it could have a property that returns the full salutation.

Though not as important, it would be nice if the plugin would work in Chrome too.

like image 216
Lost Plugin Writer Avatar asked Sep 15 '08 13:09

Lost Plugin Writer


People also ask

How do I add plugins to Firefox?

Click the menu button. , click Add-ons and Themes and select Recommendations. To install a recommended add-on, click the blue + Install Theme or + Add to Firefox button, depending on the type of add-on.

Where is the plugins folder for Firefox?

Profile directory/plugins, where Profile directory is the directory of the current user profile. ~/. mozilla/plugins. /usr/lib/mozilla/plugins (the 64-bit Firefox checks /usr/lib64/mozilla/plugins as well).

How do I unblock a blocked add-on in Firefox?

Find the one like this: extensions. blocklist. url and it will say something about mozilla. You click it to edit and just remove all of that.


1 Answers

If you need something that works cross-browser (firefox and ie), you could look at firebreath: http://www.firebreath.org

For general "how to build a npapi plugin on windows" information, I have a few blog posts on the subject (linked to from some of the above sources as well)

http://colonelpanic.net/2009/03/building-a-firefox-plugin-part-one/

I really recommend firebreath, however, since we created it exactly for people who don't have time to do the months (literally) of research that it took us to figure out how it all works. If you don't want to use it as a basis for your plugin, though, you can still find a lot of good example code there.

should work on chrome, firefox, and safari on windows too! =]

good luck!

like image 74
taxilian Avatar answered Sep 18 '22 16:09

taxilian