Page 1 of 1

I've found a fix for browser-wide-on images

Posted: 22 Jun 2008, 12:22
by markfiend
http://userscripts.org/scripts/show/7780

(greasemonkey script for firefox)

Posted: 22 Jun 2008, 12:40
by lazarus corporation
Nice find!

Posted: 22 Jun 2008, 13:00
by 6FeetOver
I found one a long time ago - it's called "Photoshop." :lol: :P

Posted: 22 Jun 2008, 13:10
by markfiend
:P Bog off :lol:

This one works on any and all websites, including ones we don't have moderating privileges on...

Posted: 22 Jun 2008, 13:18
by Obviousman
Looks cool, so I just downloaded this, now how can I get it to work?

Posted: 22 Jun 2008, 14:06
by EvilBastard
markfiend wrote:This one works on any and all websites, including ones we don't have moderating privileges on...
:eek:

I've heard tell of such sites, but never believed that they existed.

Posted: 22 Jun 2008, 17:02
by markfiend
Obviousman wrote:Looks cool, so I just downloaded this, now how can I get it to work?
Have you got the greasemonkey extension for firefox? It's a script for that.

It should just work.

Posted: 22 Jun 2008, 17:25
by weebleswobble
I've got a greased monkey :innocent:

Posted: 22 Jun 2008, 20:07
by mh
Nice one Mark. :notworthy:

A small suggested modification (to preserve the aspect ratio and reduce to 60%):

Code: Select all

// Written by Yan Huang

// ==UserScript==
// @name          Yan's Code...Pwnage!
// @description   Pwnage!
// @include       http://*
// ==/UserScript==

var z = document.getElementsByTagName ('img');

for &#40;i = 0; i < z.length; i++&#41;
&#123;
	if &#40;z&#91;i&#93;.width >= screen.width * 0.60&#41;
	&#123;
		var aspect = &#40;z&#91;i&#93;.width / z&#91;i&#93;.height&#41;;

		z&#91;i&#93;.width = screen.width * 0.60;
		z&#91;i&#93;.height = z&#91;i&#93;.width / aspect;
	&#125;
&#125;

Posted: 22 Jun 2008, 20:37
by Obviousman
markfiend wrote:
Obviousman wrote:Looks cool, so I just downloaded this, now how can I get it to work?
Have you got the greasemonkey extension for firefox? It's a script for that.

It should just work.
Got it, should've installed that first. Doh...

I'll change it to mh's version, sounds better to me!

Posted: 22 Jun 2008, 21:18
by markfiend
No need, it preserves aspect ratio anyway.

Although funnily enough I changed 0.75 to 0.6 too.

Code: Select all

// Written by Yan Huang

// ==UserScript==
// @name          Yan's Code...Pwnage!
// @description   Pwnage!
// @include       http&#58;//*
// ==/UserScript==

var z = document.getElementsByTagName&#40;'img'&#41;;
for&#40;i=0;i<z.length;i++&#41; &#123;
if&#40;z&#91;i&#93;.width >= screen.width*0.6&#41; &#123;
	z&#91;i&#93;.width = screen.width*0.6;
	&#125;
&#125;
Edit to add: mh WTF have you done with the code format man? Opening braces on their own line? What's that all about? ???

Posted: 22 Jun 2008, 21:28
by mh
markfiend wrote:Edit to add: mh WTF have you done with the code format man? Opening braces on their own line? What's that all about? ???
:twisted: :twisted: :twisted:

Posted: 23 Jun 2008, 20:41
by markfiend
mh wrote:
markfiend wrote:Edit to add: mh WTF have you done with the code format man? Opening braces on their own line? What's that all about? ???
:twisted: :twisted: :twisted:
:lol: That's just evil though. I had it formatted by the one true code format :twisted:

Posted: 23 Jun 2008, 20:58
by mh
markfiend wrote:
mh wrote:
markfiend wrote:Edit to add: mh WTF have you done with the code format man? Opening braces on their own line? What's that all about? ???
:twisted: :twisted: :twisted:
:lol: That's just evil though. I had it formatted by the one true code format :twisted:
Image

Posted: 23 Jun 2008, 21:11
by markfiend
Indeed ;D

Posted: 20 Aug 2008, 09:41
by markfiend

Code: Select all

// ==UserScript==
// @name           shrinkylinks
// @namespace      http&#58;//www.markfiend.com/scripts
// @description    For blogs and messageboards&#58; if the link text is the same as the link destination, changes the link text to 'Clicky'
// @include        *
// ==/UserScript==

var z = document.getElementsByTagName&#40;'a'&#41;;
for&#40;i=0;i<z.length;i++&#41; &#123;
	if&#40;z&#91;i&#93;.href == z&#91;i&#93;.innerHTML && z&#91;i&#93;.href != ''&#41; &#123;
		z&#91;i&#93;.innerHTML = 'Clicky';
	&#125;
&#125;
So (for example) ebay links that are 3miles long and (also) give your browser a widey, get changed to 'clicky'

Posted: 20 Aug 2008, 10:03
by emilystrange
yes but what do i DO with it?

Posted: 20 Aug 2008, 10:11
by markfiend
1: Install the greasemonkey addon for firefox -- https://addons.mozilla.org/en-US/firefox/addon/748

2: Tools -> Greasemonkey -> New User Script...

3: In the dialogue boxes, put 'shrinkylinks' under name, any URL in the namespace, then click OK

4: it'll open a text editor. Delete everything and paste in the code above.

5: Save.

Oh by the way I forgot to include this bit: (not needed for the code to run -- 'copyleft' attribution.)

Code: Select all

// This script is provided under the terms of the GNU General
// Public License, version 3, which can be found at
//   http&#58;//www.gnu.org/copyleft/gpl.html
// Specifically, note that this script comes with NO guarantees,
// not even the implied guarantee of merchantibility or fitness for a 
// specific purpose.

Posted: 20 Aug 2008, 10:20
by markfiend
Scrap that.

1: Get greasemonkey as above
2: go to http://userscripts.org/scripts/show/32138 where I've uploaded the script and click 'Install this script'

Posted: 20 Aug 2008, 10:22
by emilystrange
well that would have gone so much better if it had opened a text editor...

Posted: 20 Aug 2008, 10:23
by markfiend
Really? ???

Anyhoo, see easier installation of the script in previous post. Sorry.

Posted: 20 Aug 2008, 10:44
by emilystrange
done it! fank oo xxx

Posted: 20 Aug 2008, 11:22
by markfiend
Pleasure.

If it's working, all the links on this thread will now say [url=http://#]Clicky[/url] ;D

Posted: 21 Aug 2008, 00:38
by James Blast
this MacGimp cannae get it tae work, can I book a tutorial for tomorrow?