Add-ons

Add-ons

Add-ons

Selenium has a API that allows anyone to create new add-ons for Selenium IDE. These add-ons differ from the user extensions, in that they are Mozilla Firefox add-ons that Selenium can access.

The following steps can also be used to create a normal Firefox add-on. Firstly, create a folder on your hard drive. Everything that follows will be done within that folder.

  • Open your favorite text editor.
  • Create a file called install.rdf and add the following snippet. This file tells Mozilla Firefox what is needed to install this add-on.
  • Create a new file called chrome.manifest in the root folder. This file lets the Mozilla Firefox add-on know where all the different bits of information are.
  • Create a file called options.xul
  • In the options.xul file, you can add JavaScript so that when something is clicked, it can run a snippet of code. This means that you do not need to make something run automatically.
  • Create a folder called code in content.
  • Create a file in code to hold your code snippet.
  • The snippet will need to have a name of what it will be recognized as. In the previous snippet, we called it CheckBox. Adding this.name = ‘Checkbox’; will do it. You can now add other functions that you may find useful.
  • When you have created everything you want, zip up the root folder. Once this has been done, rename the file so that its file type is .xpi. The file type is normally the last three letters in the name that follows the last full stop.

Creating an add-on relies on understanding basic programming.

 

Selenium professional free practice test

Go back to Tutorial                                                                                Go to Home Page

User extensions
Selenium RC | Selenium Webdriver

Get industry recognized certification – Contact us

keyboard_arrow_up
Open chat
Need help?
Hello 👋
Can we help you?