LW_HL
August 5, 2015, 3:21pm
1
Hello everyone.
I’m very new to this but I intend to develop an add-on for Mozilla Firefox by using Python.
Is this possible and are there any compatibility issues?
I have done some research and am still unsure if it is encouraging to use Python for the development.
I just know a little about PyXPCOM and that I have to use this to develop the add-on in Python, is this true?
Are there tutorials or materials that use Python to develop add-on, this would definitely help a bunch as development in Python is very limited.
Kindly advice, thank you.
1 Like
leo
(Leo McArdle)
August 5, 2015, 3:35pm
2
Moved from Uncategorized to appropriate category.
TheOne
(Andreas Wagner)
August 5, 2015, 3:56pm
3
Add-ons are mostly written in JavaScript, see MDN .
noitidart
(Noitidart)
August 5, 2015, 6:00pm
4
What’s your addon idea i can give you a simple template to start off.
However if you’re very new it might be easier to kick it off with addon sdk:
https://developer.mozilla.org/en-US/Add-ons/SDK/Tutorials/Getting_Started_(jpm)
LW_HL
August 5, 2015, 6:14pm
5
Well, I didn’t actually have much of a choice as it is a task to write my system using Python, therefore I hope to use Python to make the add-on. Any suggestions or advice?
LW_HL
August 5, 2015, 6:16pm
6
Hmm, my system reads URLs, maybe you can provide a simple template on that?
However, my main question is still this; is an add-on possibly done via Python? It is my task to make my system using Python.
Otherwise, are there suggestions?
TheOne
(Andreas Wagner)
August 5, 2015, 8:04pm
7
No, it is not possible to write Firefox Add-ons in Python. Your best shot is still JavaScript. You might want to have a look at our Add-on SDK . It sounds like it could fit your needs.
1 Like
noitidart
(Noitidart)
August 6, 2015, 3:13am
8
Can you elaborate more I can really hook you up with a good solid start.
LW_HL
August 6, 2015, 5:30am
9
Is it possible to create a script based on Python then have the add-on made in JavaScript to execute the script?
The script will expect user prompts and redirect web pages as I plan to make a toolbar.
LW_HL
August 6, 2015, 5:31am
10
I’m planing to make a security system as this is my university project.
It detects malicious links and then my system needs to act upon them by redirecting user and warn the user too.
My project requires me to use Python to develop the system. However, I’m still finding ways to make this system available as an add-on browser in Mozilla Firefox. I really need guidance and materials to develop my system.
Kindly advice, thank you.
noitidart
(Noitidart)
August 6, 2015, 4:54pm
11
Yes you can execute exe’s and other things from the addon using child_process: https://developer.mozilla.org/en-US/Add-ons/SDK/Low-Level_APIs/system_child_process
I think you should give addon sdk a shot because running things is possilbe and I do it, but its not as easy as system_child_process.
Check out content scripts to do the link finding and checking for you: https://developer.mozilla.org/en-US/Add-ons/SDK/Guides/Content_Scripts
Then port emit it back to your main.js code and in there execute it with your python script.
2 Likes
LW_HL
August 7, 2015, 3:36am
12
All right, then I shall proceed with making out my script first.
Should there be any problems or enquiries, I will post further.
Thank you very much, your reply was very helpful.
David_Camp
(David Camp)
December 24, 2020, 4:02pm
13