greasemonkey

Multiple Greasemonkey Metablocks

I'm trying to write a Greasemonkey script for a heirarchy of websites such that I have a bunch of code modifications for http://www.foo.com/*, then more specific ones for http://www.foo.com/bar/*, and still others for http://www.foo.com/foobar/*. Is there anyway for me to write all these in the same script, or do I have to make multiple...

Rewrite parts of a URL in Greasemonkey and FireFox

A friend of mine uploaded about 20 or so galleries of nature shots she's done over the past year or so onto webshots.com, however, I just purchased a paid flickr account for her as a birthday gift, and I want to download all of her photos from webshots and have them ready for her to upload to flickr once she gets the email about her acco...

Is it possible to get the min and max value with jQuery and render it in another input-field?

Hello, and there we go: I'm writing(in fact it feels more like trying and asking) a GreaseMonkey script using JS and including(also using) the jQuery library. I created another table with some input-fields. Example(input-fields-only): + " < input type=\" text\" id=\" field_1\" name=\" min_field_1\" value=\"\" > " + " < in...

Using arrows-keys to navigate

Hello all, I am wondering if there was a possibility to navigate with arrow keys through a table I created with JS(using jQuery)? I mean jumping from cell to cell...The script is for Greasemonkey. The alert, however, works. I just got no idea how to make it well-functioning. $(document).keydown(function(e){ if (e.keyCode == 37) { ...

javascript how greasemonkey works

I read "Dive into Greasemonkey" written in 2005. It mentions that Greasemonkey wraps a user script in an anonymous function wrapper. Does Greasemonkey insert the wrapper into the source JavaScript code or add it as any event handler such as window.onload? ...

creating a configuration pane in javascript

I am looking to create a generic config pane for a grease monkey plugin. I was wondering if there exists a lib to make this easier? I am looking for some tool where you might give it some name/value pairs and it will generate a nice looking UI. I think ive seen this somewhere but forgot the search terms. ...

greasemonkey: stop embedded JS from running

A page has the following in the html: <script type="text/javascript"> // some code </script> My greasemonkey script needs to prevent that script from running. How can I do this? Update: I understand that in the general case this is impossible. However, in my specific case, I may have a loophole? <script type="text/javascript"> ...

javascript: call an embedded function from a GM script

On a webpage there's <script> function fn982734() { // some code } </script> In my Greasemonkey script, I have the following code: var fn = fields[5].getElementsByTagName("a")[0].getAttribute('onclick').substr(7,11); console.log(fn); // outputs fn982734 to the firebug console window[fn](); This code does not work, and s...

Greasemonkey: How to create a link from text based on specific preceding HTML

I'd like to turn some text into a link, based on it's position in the document. The preceding HTML is consistent at each instance of the text which needs to be converted, but the text itself is not consistent. The link to be created would be in the form... <a href="path/to/[text]">[text]</a> where [text] is the text in question, and pat...

How to make synchronous AJAX calls in greasemonkey?

Hello, I have a list of URLs and need to load each page, one after another. This is my main function that i have in my Mind. mainFunction() { loop { // Loop through URL list oPage = func1(URL); //Get page contents aResult = func2(oPage); //Analyse the contents func3(aResult); //Do current page modifications } } func1 uses GM_xml...

greasemonkey: addEventListener questions

I've a userscript as the following: document.addEventListener('click', alert('hello monkey'), true); There were two problems: "hello monkey" is alerted only when refreshing the browser, not work when clicking window. using GM's 'manage user script' to edit the script, the change doesn't happen. (The source code on the local disc was...

is greasemonkey a build-in extension of google's chrome

I'm trying both greasemonkey and google's chrome extensions. And found that chrome seems using the same names of api as GM. (Seem having the same bug...) Just wondering whether greasemonkey is already a google's chrome extension? ...

GreaseMonkey Log In Script

I've been trying to figure out how to write a greasemonkey script to log me into a 401 html page. When I'm asked for a username and password in a pop up box (401 Request I believe), i want it to automatically log me in (my company's design sites are all the same username and password). Any help? Also, save passwords won't work because...

postMessage doesn't work in GreaseMonkey because it cannot acces contentWindow property on cross-domain iframe but in pure Firefox it will work

here are bunch of codes isolating this problem: create 3 files on local server: test.html <SCRIPT language="JavaScript" SRC="http://localhost/postmsg.js"&gt;&lt;/SCRIPT&gt; <iframe src="http://127.0.0.1/iframe.htm" id="iframe"></iframe> <div>Click anywhere on this page to see message from embedded iframe, which do not need to be on ...

Modifying all links w/ Greasemonkey

Hello. I want to mod a page from a site that prefixes all its links with "http://linkblur.com/?" I tried this: links = getElementsByTagName('a'); for (l in links) { l.href = l.href.replace('http://linkblur.com/?',''); } But it doesn't work. What am I doing wrong? tks Steve ...

Protect Greasemonkey scripts?

I know that anything that is downloaded and is in the user's possession is going to be pretty hard to protect, but I'm just wanting to hear opinions. I'm thinking of selling a script (made with Greasemonkey...), and I want to be able to prevent the user from easily viewing the source code, or sending it to others. Thanks in advance. ...

Change css locally per domain.

I want to add css to pages with a certain url in much the same way that greasemonkey adds javascript. I guess I could inject some css with a script but that isn't as clean. Are there any browser plugins that let me do this? Doesn't necessarily need to be a Firefox one. ...

Adding keylistener and using javascript to click a link in Greasemonkey

Hi , I want to create a greasy monkey script , which will add a shortcut key for logout action in one mail site. Currently the logout link "?logout&hl=en" which have an id=":r5". I am able to get the node for the link but not able to call click on it. I tried the script as following function key_event(event){ GM_log("Hello"); ...

How can I resize the recaptcha in Greasemonkey?

I want to re size the text from the captcha to be easier to see, with Greasemonkey. How can I do it? For example, I have this captcha: <div id="recaptcha_image" style="width: 300px; height: 57px; "> <img style="display:block;" height="57" width="300" src="http://www.google.com/recaptcha/api/image?c=03AHJ_VuuqeICMpU36GlHCSchBzERwiDzT...

Is it possible for a greasemonkey script to automate the Ctrl+A (select all) action in firefox ?

Is it possible to write a Greasemonkey script to trigger the Ctrl+A (select all) action in Firefox? (after a new page is loaded if the script is enabled???) Help me at any level possible for you. Update: "Firefox has got addons to speed read or read aloud selected text. I just wish to automate the part where text is to be selected....