I'd like to write a plugin for Firefox with the idea of taking HTML code user is presently onto, process it and send it to external php script.
How would you proceed? What programming languages can I use?
There is a wealth of information available online to help you create Firefox extensions.
Here are some good ones:
Firefox Extension Development Tutorial :: Overview
How To Develop A Firefox Extension
Getting started with extension development
Related
I'm trying to set up Copper on Firefox version 53.0.3 and I am aware that the extension/plugin is not available anymore for Firefox 56+. I followed the instructions on how to set it up (https://github.com/mkovatsc/Copper) and I'm stuck at creating the text file copper#vs.inf.ethz.ch in the extensions directory of my Firefox profile. I noticed that the extensions file should be an .xpi file. Do I need to write anything in the file like any other Firefox extension to make it work?. I'm pretty new at this and I could use some help from more experienced people. Thank you and have a nice day.
Try in chrome browser!It perfectly works for me.Firefox in Cu4r is a little complex.
I have a question on Flash Automation. I want to automate my website which is in flash. where i have to login, create users , scroll down and find users.
Can i Automate it using selenium RC if not please suggest some good open source tools.
Thanks
If you don't manage to pull off what you want to do using Selenium RC. Try using Sikuli (found at http://www.sikuli.org/ ). You can use the Sikuli IDE, which works a lot like Selenium IDE, or try using the libs with java per example. They've got some examples on the site where you'll see how to use the image recognition to find certain elements and add/edit the data present there. Hope this helps.
I would like to define different actions for different pages
I would like to do like this, when I entry :
wwww.test.com/page1.html : alert Hello!
wwww.test.com/page2.html : alert Good morning!
wwww.test.com/page3.html : alert Hi!
How do I implement this idea
Any tutorial links? thinks so much!
There are three general types of Firefox add-ons: Overlay, Restartles (Bootstraped), and using the Add-on SDK (Software Development Kit). There is a good article comparing the three types on MDN (Mozilla Developer Network).
In general, the most flexible are Overlay extensions. Bootstrapped (Restartless) extensions sacrifice some of the capabilities available to overlay extensions for the ability to install and uninstall without requiring the user to restart Firefox. Add-on SDK extensions sacrifice a considerable amount of the capabilities available to the other two types of extensions for having an abstraction layer between the extension writer and the guts of Firefox. The Add-on SDK is intended to make writing extensions easier and reduce the amount of work needed by the person writing the extension to maintain compatibility with future versions of Firefox. It mostly succeeds at this, but it does fail in some ways.
There are tutorials available on MDN:
Getting Started with Firefox Extensions
XUL School Tutorial
Building an extension
Add-on SDK Tutorials (many)
Many more
MDN is a good resource for information about extensions. When working on Firefox extensions I typically have at least one tab open to a Google search for "MDN " and then whatever I am looking for. It is my go-to method of finding documentation for developing Firefox extensions.
There are a couple of forums which have good information:
Mozilla Add-on Forum (Official)
mozillaZine
Welcome to developing extensions for Firefox.
As to the specific question you asked, the exact code depends on if you are using the Add-on SDK, or not. For the SDK, you should read Working with Events and Listen for Page Load among others. For the other types: Intercepting Page Loads, Listening to events in Firefox extensions, and On page load (Code snippet); also among others.
I am attempting to test several web pages built in Flex, and need to automate clicking on several videos through the Flash interface. I'm using Ruby and Watir-Webdriver, but I'm not sure how to interact with Flash using them.
Has anyone figured this out? I've tried using Sikuli, but have found it to be a little clunky and not very fast. Any ideas would be greatly appreciated.
I will quote myself:
It is important to say that Watir CAN NOT control browser plugins like
Java applets, Adobe Flash or Microsoft Silverlight.
From https://github.com/zeljkofilipin/watirbook/blob/master/about.md
There is a way though. You can embed javascript into your ruby watir script.
It has worked for me
browser.execute_script <<-JS
Global.videoPlayer.sendEvent("play")
JS
Similarly you can do a pause or stop based on the controller on the player
Enjoy !!
What are the minimum programming requirements to create a Firefox plugin?
You need to learn XUL for the UI and Javascript for the programming.
more infos here:
https://developer.mozilla.org/En/Developing_add-ons
Firefox plugins (such as things like Flash player) are binary components you develop in NPAPI the cross-browser API for plugins.
Check out Mozilla Plugin Developer Center
You might also look into Firefox Extensions sometimes Firefox plugins are shipped as extensions. Firefox extensions modify or enhance the functionality of the browser itself. Javascript is primarily the language you'll be writing a Firefox plugin.
Check out the Mozilla Extensions Developer Center
Some Firefox plugins that come in handy when developing Firefox plugins are the Venkman Javascript Debugger and Firebug Javascript debugger
If you are into an organized style of reading, and prefer an good ol' book, start here.
http://www.amazon.com/Programming-Firefox-Building-Internet-Applications/dp/0596102437
It will get you started on the basics on XUL, which is in turn used to build the addons. If you have a touch in javascript, it will definitely help you.
Else,
Start here.
https://developer.mozilla.org/En
You can start learning what all you will need to start developing firefox addons, or even firefox itself.
If you are fairly proficient in Javascript and DOM, then, just jump here.
https://developer.mozilla.org/En/Developing_add-ons.
The only problem might be, they are as not comprehensive for a newbie programmer. If you have some professional background in programming, and can pick up a language from sample codes, then start here.
But I would definitely suggest a well organized book, like I mentioned above. There are very few XUL book in the market, this was my first google result, so just linked it here.
Search for XUL on http://www.amazon.com/.Choose one, atleast a book published after 2006-07.
[edit]
Just found out this good article
http://kb.mozillazine.org/Getting_started_with_extension_development
There seems to be a huge misunderstanding here; Are you trying to create a plugin or an extension? As Dougnukem stated, plugins have nothing to do with XUL or extensions. They are shared libraries (.dll, .so, or .dylib for win, linux, mac) that provide functionality that the browser isn't capable of alone.
If you're just getting started, I'd recommend looking at the FireBreath plugin framework and reading through some documentation. A decent place to start is: http://colonelpanic.net/2009/03/building-a-firefox-plugin-part-one/
Also, you still haven't selected an answer for this question; is that because you haven't found an answer yet, or because you've forgotten?
Advanced DOM, the Firefox API