-1

i tried to write a script which can be added as an extension to the browser. The problem with this script is how to access the dom elements of a webpage. i used XMLHttpRequest object for accessing the web page but it has same origin policy issues. I worked on it for nearly 3 weeks finally i used Anyorigin.com code but i am not able to get all the functionality so i thought of using userscript where we can easily access the web page's DOM elements. Is ther any other way to create an extension

user1335906
  • 145
  • 12
  • Duplicate of [How To Create a Quick Minimal Firefox Extension](http://stackoverflow.com/q/274639/331508) and also [Convert JavaScript into Firefox extension](http://stackoverflow.com/q/9234642/331508). – Brock Adams Apr 18 '12 at 05:33

2 Answers2

0

Try this:

Greasemonkey: Customize the way a web page displays or behaves, by using small bits of JavaScript.

https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/


Update:

This looks to be a better solution, but I haven't tested it.

http://crossrider.com/

enloz
  • 5,704
  • 9
  • 37
  • 56
  • Yes Now i am creating userscripts but for this we have to download Greasmonkey that is why i am asking is there any other alternative – user1335906 Apr 18 '12 at 04:38
  • I even tried converting userscript to firefox extension using [Userscript Complier](https://arantius.com/misc/greasemonkey/script-compiler.php) but it didn't work – user1335906 Apr 18 '12 at 04:41
0

While enloz's answers are good, Firefox has an Add-on Builder that you can you use.

Add-ons are built using HTML, CSS and JavaScript. There is a web based version with the following features (quoting from their website):

  • Edit code in a feature-rich environment
  • Test your add-ons instantly
  • Use built-in version control & sharing

You can find the web based version here: https://builder.addons.mozilla.org/

Elvis D'Souza
  • 2,273
  • 1
  • 23
  • 31