Questions tagged [greasemonkey]

OBSOLETE as of Firefox 57. Use [greasemonkey-4] or [tampermonkey] as applicable. If using some other browser userscript engine, use [userscripts].

OBSOLETE as of Greasemonkey 4 -- which is a major change that is not backwards compatible.


Usage Hint

Use this tag if you are using Firefox, pre version 57. Use the tag if you are using Tampermonkey on Chrome. For all other userscripts, please use the tag.

GreasemonkeyMain add-on page is a userscript manager for Firefox. Userscripts are written in JavaScript, and run in every page as specified by the @include, @exclude, and @match rules.

Greasemonkey also permits special operations that ordinary javascript is not allowed to do. See the Greasemonkey API.

Userscripts are also available on/for other browsers; see the tag wiki of .
Important: Please use only if you are running the Firefox browser and/or using the add-on.
For all others, use , if it applies, or .


Premade userscripts:

Premade userscripts can be found at:


References:

2842 questions
1
vote
2 answers

Storing variables used in greasemonkey script from website

On a certain homepage I visit I want to hide all links that I click. My idea was to use a Greasemonkey script like this: var blocklist = JSON.parse(GM_getValue("blocklist")); var as = document.getElementsByTagName('a'); var alength = as.length; …
Ikarus
  • 43
  • 6
1
vote
1 answer

No alert or log output from my Greasemonkey script?

Update: The OP now confirms that the problem occurred due to Greasemonkey being disabled. I am trying to make a simple Greasemonkey script, however it doesn't appear to do anything and nothing relevant appears in the console. The script: //…
gandalf3
  • 1,636
  • 4
  • 24
  • 40
1
vote
2 answers

Greasemonkey script injection

I'm using greasemonkey to inject a script into every page that loads in my browser. The problem that i'm facing now is that, if the browser moves from one page to another within the same domain, greasemonkey doesn't inject my script again. For…
kambamsu
  • 11
  • 4
1
vote
0 answers

Create a post request within an Iframe using Greasemonkey

I am rendering an Iframe within a greasemonkey script, which renders a webpage from my back-end webservice. At the minute I can make a GET request and everything works fine but going forward my URL will be enormous if I want to pass more content to…
Ciaran
  • 1,139
  • 2
  • 11
  • 14
1
vote
1 answer

Attempt to modify HTMLTableRowElement.prototype

I have two methods, working nicely in couple of pages, but when it comes to a Greasemonkey script they fail for some reason, throwing an 'is not a function' error. The very same code, while attached normally to the page, works perfectly.…
AlexTR
  • 772
  • 8
  • 14
1
vote
2 answers

How to get JavaScript variable from ajax loaded page with jQuery?

I'm developing userscript for one webpage (aka browser plugin). I need to update one global Javascript variable (lets call it gVariable (it is an array)) with the one I get with ajax request. In ajax request I'm requesting for the same page I'm on.…
Hooch
  • 28,817
  • 29
  • 102
  • 161
1
vote
1 answer

Can I use Google Analytics to track usage of a Greasemonkey script?

I've got a greasemonkey script and I'd like to get an idea of how many regular users I have, what I'd really like is to use Google analytics inside the script. But I'm not sure how to do it if it's even posible. Also, the site the GM script is…
Ben Shelock
  • 20,154
  • 26
  • 92
  • 125
1
vote
4 answers

Get contents of another site's element using only JavaScript

I'm making a userscript that requires finding a word related to another word. I found a site where I can go to http://semantic-link.com/#/stack, and there will be a list of words related to stack in the format of: